Git Product home page Git Product logo

cwrceditor's People

Contributors

jchartrand avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

Forkers

ajstanley

cwrceditor's Issues

reimplement css tag formatting

Formatting based on the events css is gone. I know you told me why this was Andrew, but I can't remember. Can we add it back in?

scrolling drop down for unassigned tags

Any tags without a button should appear in the structural drop down (the drop down with the angle brackets.) The drop down should be (ideally) multicolumn and scrolling. Scrolling is essential.

When the server side validation/suggestion service is available, then we'll look at incorporating contextual tag filtering, as a separate issue.

tei header popup

Create a popup that can be invoked from two places:

the TEIHeader element in the structure view.
a new button that appears up in the top right of the editor, labelled Edit Header

In fact the TEIHeader element in the structure view should, when clicked, only open the popup. That particular element should have no other menu options, including no right click menu.

The popup itself should show the elements in the header as a form. This is an first pass at the header so include those elements that seem obvious, and list in an email those about which you are unsure.

Editor Freezing While Tagging and Deleting Tags in Firefox

A tester using Firefox (didn't say version):
If the cancel button is X, then it's frozen. [When tagging person] I first successfully tagged two names already on the list, although the second one, Linda Bree, was odd. The list appeared; it did have the right name on it; I clicked on that name; everything froze for quite a while, including the X button, and then it suddenly worked. But the next name, not on the list, does the same thing. The red bars for tagging have appeared in my text but I can't make the Add Person list go away, or the X work. And since the text is frozen I can't try tagging an organization or whatever.
Ok, so I re-opened and this time thought I shd try some structural tags. So I tried inserting a paragraph (wondering how it wd look since the pasted text has paras already). But the list with stack of paragraph tags won't go away (that is, close) either. I then tagged an Orgname and same thing: I have got the box saying Add Organization, which won't go away, and everything is frozen again.

Allow alternate identifiers in Person popup.

Modify the Person popup to allow directly typing the URI for a person into one of several fields, rather than having to look it up in CWRC system. Add the following fields for specifying the URI:

Name: __________ include some help text: "Enter a first and last name, which will be encoded as a FOAF URN."

Local Identifier: _________ with help text: "enter the local id that you system uses for this person. It will be encoded as a URN"

URI: __________ with help text: "Enter a resolvable URI that identifies this person, e.g., their VIAF uri, LOC uri, etc."

Put these options in some collapsible (hidable) part of the popup, collapsed by default. Indicate the availability of these other options as 'Use Alternate Identifier"

At some point we'll probably also want to provide options for doing a lookup in VIAF or other authority list, directly from the popup. In fact it looks like VIAF has a web service:

http://www.oclc.org/developer/documentation/virtual-international-authority-file-viaf/request-types
http://www.oclc.org/developer/documentation/virtual-international-authority-file-viaf/response-details

If it doesn't appear to be too difficult, could try to include this in the popup as an alternate lookup service. Could we even put two radio buttons: 1.use CWRC, 2. use VIAF
and search the given service accordingly?

enable copy/paste of full entities

Allow users to right click on an entity, either in the left hand entry browser, or in the right and editing pane, and select the entity for copy. Then should then be able to paste a new instance of the entity anywhere in the text.

help from schemas

Mariana has created annotated versions of the schemas:

http://cwrc.ca/schema/events
http://cwrc.ca/schema/common

Could you take a look and determine how best we can incorporate the help text provided in the annotations into the editor?

Ideally we'd like to indicate that help is available for each tag, by including a question mark that appears in a circle next to the element when shown in the drop down list, or wherever would be most appropriate.

incorporate orlando css for elements

Look at incorporating the css that is otherwise used to render the orlando events schema in Oxygen. This is the css:

EVENTS {
font-family: "Times New Roman", Times, serif;
}
ORLANDOHEADER {
display: block;
font-family: Verdana, Geneva, sans-serif;
font-size: small;
}
FILEDESC {
content: url(../images/theorlandoproject.gif);
background-color: #990000;
color: #FFF;
font-weight: bold;
}
DOCTITLE {
font-variant: small-caps;
font-size: x-large;
font-weight: normal;
}
FILEDESC,
DOCAUTHOR,
DOCEDITOR,
DOCEXTENT,
PUBLICATIONSTMT,
TITLESTMT,
PUBPLACE {
display: list-item;
}
RESPONSIBILITY {
font-family: Verdana, Geneva, sans-serif;
font-size: small;
background-color: #F0EDFC;
display: list-item;
}
EMPH {
font-style: italic;
}
FOREIGN {
font-style: italic;
}
TITLE[TITLETYPE="MONOGRAPHIC"], TITLE[TITLETYPE="JOURNAL"] {
font-style: italic;
font-weight: bold;
color: #336699;
}
TITLE[TITLETYPE="SERIES"] {
font-style: normal;
font-weight: bold;
color: #336699;
}
TITLE[TITLETYPE="ANALYTIC"], TITLE[TITLETYPE="UNPUBLISHED"] {
font-style: normal;
font-weight: bold;
color: #336699;
}
TITLE[TITLETYPE="ANALYTIC"]:before, TITLE[TITLETYPE="UNPUBLISHED"]:before {
content: open-quote;
}
TITLE[TITLETYPE="ANALYTIC"]:after, TITLE[TITLETYPE="UNPUBLISHED"]:after {
content: close-quote;
}
ADDRLINE {
display: list-item;
}
IDNO {
display: list-item;
}
AVAILABILITY {
display: inline;
}
P {
display: block;
}
RESEARCHNOTE {
background-color: #FBEFEF;
color: #663366;
font-family: Arial, Helvetica, sans-serif;
font-size: smaller;
display: list-item;
}
HEADING {
display: list-item;
font-weight: bold;
font-size: x-large;
color: #39;
}
CHRONSTRUCT {
display: list-item;
}
CHRONSTRUCT DATE {
font-weight: bold;
}
CHRONSTRUCT[CHRONCOLUMN="BRITISHWOMENWRITERS"] {
content: url(../images/pen1.gif);
}
/*
CHRONSTRUCT[CHRONCOLUMN1="BRITISHWOMENWRITERS1"]{
content:url(../images/pen1.gif);
}
CHRONSTRUCT[CHRONCOLUMN2="BRITISHWOMENWRITERS2"]{
content:url(../images/pen1.gif);
}
CHRONSTRUCT[CHRONCOLUMN3="BRITISHWOMENWRITERS3"]{
content:url(../images/pen1.gif);
}
/
CHRONSTRUCT[CHRONCOLUMN="NATIONALINTERNATIONAL"] {
content: url(../images/earth1.gif);
}
/

CHRONSTRUCT[CHRONCOLUMN1="NATIONALINTERNATIONAL1"]{
content:url(../images/earth1.gif);
}
CHRONSTRUCT[CHRONCOLUMN2="NATIONALINTERNATIONAL2"]{
content:url(../images/earth1.gif);
}
CHRONSTRUCT[CHRONCOLUMN3="NATIONALINTERNATIONAL3"]{
content:url(../images/earth1.gif);
}
/
CHRONSTRUCT[CHRONCOLUMN="SOCIALCLIMATE"] {
content: url(../images/people1.gif);
}
/

CHRONSTRUCT[CHRONCOLUMN1="SOCIALCLIMATE1"]{
content:url(../images/people1.gif);
}
CHRONSTRUCT[CHRONCOLUMN2="SOCIALCLIMATE2"]{
content:url(../images/people1.gif);
}
CHRONSTRUCT[CHRONCOLUMN3="SOCIALCLIMATE3"]{
content:url(../images/people1.gif);
}
/
CHRONSTRUCT[CHRONCOLUMN="WRITINGCLIMATE"] {
content: url(../images/book1.gif);
}
/

CHRONSTRUCT[CHRONCOLUMN1="WRITINGCLIMATE1"]{
content:url(../images/book1.gif);
}
CHRONSTRUCT[CHRONCOLUMN2="WRITINGCLIMATE2"]{
content:url(../images/book1.gif);
}
CHRONSTRUCT[CHRONCOLUMN3="WRITINGCLIMATE3"]{
content:url(../images/book1.gif);
}
*/
SHORTPROSE {
padding-left: 4em;
}
BIBCIT {
content: url(../images/bibcit.gif);
}
BIBCIT:before {
content: "(";
}
BIBCIT:after {
content: ")";
}
BIBCITS {
background-color: #FFC;
}
SCHOLARNOTE P {
content: url(../images/note.gif);
background-color: #E0E0F8;
}
NAME {
font-weight: bold;
color: #336699;
}
ORGNAME {
font-weight: bold;
color: #336699;
}
SETTLEMENT {
font-weight: bold;
color: #336699;
}
REGION {
font-weight: bold;
color: #336699;
}
GEOG {
font-weight: bold;
color: #336699;
}
AREA {
font-weight: bold;
color: #336699;
}
TOPIC {
font-weight: bold;
color: #336699;
}
QUOTE:before {
content: open-quote;
}
QUOTE:after {
content: close-quote;
}
QUOTE[DIRECT="N"]:before {
content: "'";
}
QUOTE[DIRECT="N"]:after {
content: "'";
}
SOCALLED:before {
content: "'";
}
SOCALLED:after {
content: "'";
}

Add setting to change editor mode

Let the user switch between XML & RDF, and XML only modes.
When the user loads a saved document whose mode is different from the current editor mode, the editor will change to that mode.

validation

Add a validation button that sends the text to the validation service, and displays the results in a popup. Later we'll consider displaying the error in some more 'permanent' part of the editor display, like a collapsible panel over the right, or at the bottom.

Validation should also be triggered just before a save. If valid, go ahead with the save. If invalid show errors, but still give the end user the option to save anyhow.

The validation service is described here:

http://research.artsrn.ualberta.ca/cwrcxml/

The URLs for the Orlando events schema are:

cwrc.ca/schema/events ( I think you just pass this one which references the next. the validator should I think retrieve and merge the referenced schema)
cwrc.ca/schema/common

The URL for the CWRC TEI schema:

http://www.cwrc.ca/schema/cwrcbasic

So, what remains to be done I think is simply to send the right schema url to the validator on validation. i.e, the cwrcbasic when someone is editing a cwrcbasic doc and the orlando events when they're editing an orlando events doc.

OAC schema

Develop preliminary OAC schema for CWRC entities.

strip pasted xml

Whenever someone pastes XML (including, and most likely, HTML) into the editor, strip out all tags except paragraph tags. If the paragraph tags aren't properly opened and closed then strip them out.

At the moment, pasting XML (HTML) into the editor is messing up the underlying structure.

XML/RDF & XML Modes

Add XML/RDF & XML modes:

  • XML/RDF: the existing model in the editor, where named entities are marked with RDF, and can overlap. Structural tags are XML.
  • XML only: the interface would look the same, but named entities would be tagged with XML, not RDF. And so no overlap would be allowed.

current tag path

Put the full path in the top bar where we now show the current tag in which the cursor sits. Is it possible to allow any element of the path to be clicked to position the cursor in that element (essentially replicating what you can currently do with the structure tab, but in a more obvious place)

allow entity or tag to be chosen without preselecting text

As it stands if you select a tag or an entity without having already selected some chunk of text you get an error. We'd like to allow end users to select a tag without having to preselect text. This will probably cause problems with the end user knowing in what context they are working (in what tag they are positioned.) Another issue will be entered to create a new label beside the drop down that indicates the current tag. Hopefully this will help.

We may also want to allow the end user to 'turn off' a tag after they've clicked it. But that could be, for now, done by deleting the tag over in the left panel. Maybe, though, we could look at allowing clicking on the context label I described above, to turn off the current tag (removing the tag completely if there is nothing in it, otherwise closing the tag if there is something in it. By 'closing' i mean moving the cursor to just outside the tag (to the right.)

map interface to tei-lite

Create a second mapping to the editor for the tei-lite p5 schema:

http://www.tei-c.org/Guidelines/Customization/Lite/

Hopefully the entities map in a relatively straightforward way to the equivalent Tei elements.

Help files for the elements is available by hitting the following url:

http://www.tei-c.org/release/doc/tei-p5-doc/en/html/

with 'ref-' and the tag name appended like:

http://www.tei-c.org/release/doc/tei-p5-doc/en/html/ref-abbr.html

for the 'abbr' tag.

We could probably just trigger a popup showing the content of the page at the help url.

This is a big task. Feel free to break it out into smaller github Issues.

ctrlZ undoes everything

From Susan Hesemeier:

"When I clicked on cmd Z, it undid all of the changes I had made (i.e. not just the last change). Steps I took:

  1. I removed the text "cwrc", "russell", "both with password..."
  2. I removed the structural heading tag on the text "authentication" by right clicking and then selecting "remove tag".
  3. I used cmd z to undo, and everything came back (i.e. not just the last change I had made, but the previous changes as well, mentioned in 1)).
    "

allow tag name change

) 'Change Tag' should be a new option in the right click structure menu, which will change the name of the tag. The user will select from a list of contextually relevant tags.
b) 'Change Tag' hould also appear in the Edit Tag option of the right click menu.

show current tag

Add a space just to the right of the drop down, that displays current tag selected.

There is already the contextual hierarchy down at the bottom of the editor, which we'll keep, but we'd also like to more prominently display the currently selected tag (the tag in which the cursor currently sits.)

Could also look at how hard it would be to make this new label clickable, allowing the end user to click it to either remove the current tag if nothing is in it, or 'close it', effectively moving the cursor to just outside the tag (to the right.)

scroll tag list

The tag list runs off the screen when it opens.

Susan Brown also reports:

"or sometimes is placed so that it appears (only partially visible) on the upper left of the structure panel, extending beyond the screen"

Can we put it in a scrolling box, and fix the partial visibility problem?

intro screen to choose between cwrctei and cwrcevents schemas

  1. Create startup screen that appears when someone first arrives at the editor page with the following large, well spaced, buttons:

"Load an Existing Document"
"Start a CWRC-TEI Document"
"Start a CWRC-EVENTS document"
"Create a Letter with CWRC-TEI"

The "Create a Letter with CWRC-TEI" option opens the editor with the blank letter template here: https://docs.google.com/document/d/1vkP5M5f0Gi8NgK8kFOfXwcyBj4slwDtobbnid7Wtvk8/edit

The "Start a CWRC-TEI Document" and "Start a CWRC-EVENTS document" open blank documents using the requested schema.

This is the CWRC-TEI schema: http://www.cwrc.ca/schema/cwrcbasic

These other two are I think a combined schema (the events one pulls in the common one I believe):

http://cwrc.ca/schema/events
http://cwrc.ca/schema/common

and should be used for the CWRC-EVENTS option.

The load button if clicked should show the same popup as the current load button.

saveAs not working

Can't seem to SaveAs with a new name after loading an existing document.

testing out the issues tracker

seeing how this works as an issues tracker (Mariana also has another one that can pop up in the editor to have people add feedback)

select to end of paragraph incorrectly crosses paragraphs

  1. create two paragraphs in the editor
  2. select the text at the end of the top paragraph (one or two words), taking care to extend the selection (the part that gets highlighted) beyond the end of the paragraph, onto the line below, but without actually selecting (highlighting) any part of the second paragraph.
  3. click a tag

The following error appears:

"Please ensure that the beginning and end of your selection have a common parent.
For example, your selection cannot begin in one paragraph and end in another, or begin in bolded text and end outside of that text."

It seems the selection is inadvertently extending into the next paragraph even though the highlight doesn't indicate that it has.

If you take care to select text only to the end of the first paragraph, without letting the mouse move down onto the line below then everything is fine. Nevertheless, we need to correct the inadvertent crossing over.

New annotation buttons and popups

Four new entity buttons should be added and labelled:

Note
Correction
Keyword
Link

Four corresponding popups should be added for each of which I'll add a new github issue.

Add an "unsaved changes" notice on page leave

End users might inadvertently navigate away from the page, e.g., with the back button, potentially losing unsaved changes to their document. Andrew has suggested adding an "unsaved changes" notice if you try to leave the page, similar to Gmail and other sites. Good suggestion, which we'll adopt.

tag insertion point in structure panel

modify the right click option in the Structure panel to instead of just 'insert', include options to specify the following position in relation to the selected tag:

before
after
around
inside

Before - puts the tag just before the selected tag, as a sibling.
After - puts the tag just after the selected tag, as a sibling.
Around - puts the new tag around the currently selected tag, making the current tag a child of the new tag.
Inside - puts the new tag as a child of the current tag, but a child that includes any existing content in the current tag. So the new tag would be the only child of the selected tag, and would contain any children the selected tag had had.

hookup new entity system

Query API
Service Location

This service can be accessed at the following address

http://durville.cs.ualberta.ca:8084/uap?d=&f=&v=&q=&l=

There are currently four required parameters and one optional parameter:
- The name of the CouchDB database.
- The name of the Lucene index.
- The view from which you want results returned.
- The actual Lucene query.
- The maximum number of results that will be returned. The default is 50.
The results of the query is now formatted as follows. Each line contains the entire JSON object as retrieved by CouchDB.
Currently if no results are found, nothing is returned. Perhaps this will change in the future.

Sample results from querying: http://durville.cs.ualberta.ca:8084/uap?d=orlando&f=by_auth_label&v=auth_label&q=authlabel:Bar&l=5

{"_id":"1de53446152001a880affbf7ce16fe26","_rev":"1-90d84348f32bffafef5241bdd6df2661","entry":{"type":"organisation","projectID":"orlando","authorityLabel":"Bar Convent"}}
{"_id":"1de53446152001a880affbf7ce170f08","_rev":"1-96ea95aaad9abb2ba44245ed56d4ede7","entry":{"type":"organisation","projectID":"orlando","authorityLabel":"Bar of the House"}}
{"_id":"0a6ff8d62576b711807585156a6f1e05","_rev":"1-2c40acc0d54b47fbbaa3604b205449e1","entry":{"type":"title","projectID":"orlando","authorityLabel":"Anecdotes at the Bar"}}
{"_id":"128ff693b8da1387719d4f9b0567faf4","_rev":"1-233a5dee4a5bde7346f0c066b971c376","entry":{"type":"title","projectID":"orlando","authorityLabel":"Temple Bar"}}
{"_id":"1de53446152001a880affbf7ce17085f","_rev":"1-d4000b9cbc4792c826ee4fe04da3f335","entry":{"type":"organisation","projectID":"orlando","authorityLabel":"Bar Convent School"}}

Example Queries
Search for Dunn in the "authlabel" field from the orlando-test database
http://durville.cs.ualberta.ca:8084/uap?d=orlando-test&f=by_auth_label&v=auth_label&q=authlabel:Dunn
Search for the top result that contains Atwood in the "authlabel" field from the orlando-test database
http://durville.cs.ualberta.ca:8084/uap?d=orlando-test&f=by_auth_label&v=auth_label&q=authlabel:Atwood&l=1

quotations not undone from structure

from Susan Hesemeier:

"When I tag text as a quotation and then hit cmd/ctrl z to undo, the quotation tag is not removed from the left panel structure tab, even though the formatting no longer displays in the main text"

allow override of quotation formatting

Add a checkbox called 'Override standard formatting' to the quotation popup, with three radio buttons below the new checkbox (disabled unless they check the box) for the three override choices:

  1. indent
  2. quotation marks/run in
  3. no formatting/run in

If override is selected, then use the formatting specified by the chosen radio button to display the quotation in the editor. The formatting selection should also be stored in an attribute of the tag (call it format for now, until we have the correct mapping.) Select the first radio button by default when the override checkbox is clicked.

The formatting for each is as follows:

From CWRC screenshots

https://picasaweb.google.com/lh/photo/JQ5FMw5E0AsatQ_5xAqZClFXKwHATiyS5ZBS_hDYESs?feat=directlink

combine all tags in drop down

Combine all tags in the <> drop down. I.e., merge 'paragraph', 'heading', 'emphasized', and 'quotation' with all tags in the 'schema tags' sublist, and get rid of the sublist. Or in other words, move all tags in the 'schema tags' sublist up into the same list as the 'paragraph', 'heading', 'emphasized' and 'quotation' tags.

span tag interfering with tag selection context

The span tag used to mark the limits of a entity is interfering with the contextualization of tags. If you put your cursor in the text of an entity and then select the drop down <> to show
the tags that could be inserted at that point, the list is empty, because you are in a span and none of the tags are allowed in a span. At least I think that's what's going on.

Settings popup

Create a 'Settings' popup triggered by clicking on a 'Settings' link (in whatever spot in the editor seems best for the moment)

Initially the Settings popup should be titled 'CWRC Writer Settings' with the following two options:

Font Size: (a drop down list with font sizes)
Font Type: (a drop down list with some font choices, just a couple for now)

Question: how hard would it be to allow users to set their own per element styling? So say for quotations if say they wanted to italicize quotations, or maybe underline quotations.

new entity popups

Create popups for all named entities, one for each type of entity, to allow creating new entities. These are intended as strawmen to stimulate discussion so just make your best guess at what should go into each, including any validation you think would be appropriate. They won't save anywhere for the moment. Make the save button read 'Submit for Review'

brackets around non-entities

Show brackets around tags that aren't entities. Use a different bracket type (angle if that doesn't interfere with underlying tags? or maybe brace brackets.) If possible can another option be added to the Settings popup to allow disabling these non-entity brackets? But, we'd want to treat the entity and non-entity brackets separately. So the end user could disable either the entity brackets OR the non-entity brackets OR both.

cursor moves outside of new tag

When adding a tag from the drop down, without first selecting text, the opening and closing tag is created but the cursor is place outside the tags. It should be placed between the opening and closing tag.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.