The length of input fields can very quickly exceed the max URI length resulting in 414 errors when printing or exporting results.
To access the input values for a specific GridField action, encapsulate this in your own Entwine instance.
Inside mediaform updateFromEditor we called $(this).updateFromNode, but this wasnt
pointing to anything useful after a refactor, which resulted in the fields not
being filled in with current data when editing an already-inserted image
Otherwise some non-textual changes such as moving images and resizing
them could be missed when saving.
This is because TinyMCE does not treat the image move/resize as an
undolevel and does not register this via regular "onChange" event.
It was impossible to unselect TreeDropdownField.
'!' operator should not be used at all and identical comparison (===) was too "strict" (self.getValue() returns string but $(node).data('id') returns number).
The accordion widget was previously being passed true and false, where as it either expects true or the integer of the panel to show.
This fix sets it as either false or 0.
Introduces the concept of action tabsets - usage of TabSet and Tabs
in between the action buttons to allow richer set of capabilities that
can be offered to the user.
Goes along with c8d0cdec99c95dbed3b58ebcc098cc9d22c58206 that implements
a change to the CMS actions.
Makes the editor API more flexible by triggering generic JS events that
can be used from entwine. This makes it easier to add event handlers to
the editor and cleans up the initialisation call from unrelated code.
The patching code also forwards editor changes to the textarea field,
which in perspective will allow the changetracker to react to changes in
this field as they happen.
The escape and unescape functions do not work properly for non-ASCII characters and have been deprecated. In JavaScript 1.5 and later, use encodeURI, decodeURI, encodeURIComponent, and decodeURIComponent.
I have problem with cyrillic http://www.silverstripe.org/general-questions/show/21433
Put "File upload complete" and "back to folder" together. Turned 'File
upload' into a message, and updated the message styles.
Moved allowed file types into the area where users are uploading files.
This is a temporary fix until js tooltips are implemented, at which
point, these details will be shown when clicking a question mark beside
"Choose files".
Added small animation effect to files when opening iframe to edit. Now
slides down, rather than just appearing open
Linked to silverstripe/silverstripe-cms#223
Only occurs when the UploadField resources are loaded uncached.
Possible cause: Randomized application between UploadField.js
setting "display: block" and UploadField.css setting "display: none". Simply hiding the element before showing it fixes the issue.
Delayed show because TinyMCE calls hide() via
setTimeout on removing an element,
which is called in quick succession with adding a new editor
after ajax loading new markup
See e0378ceb77
and https://github.com/silverstripe/sapphire/pull/847
The entire framework repo (with the exception of system-generated files) has been amended to respect the 120c line-length limit. This is in preparation for the enforcement of this rule with PHP_CodeSniffer.
After Hamish's suggestion. Entwine onchange would not get executed in
IE8 at all, which would have the effect of the displyed dropdown
selection not being set.
Change to onadd also mandates the changes to onadd on other parts of the
tree component - otherwise the change event can trigger before the
tree elements are added to the DOM.
Space delimiter is often confused by browsers, and encoded as %20 which
breaks the shortcode system. Change to comma delimitation has already
been implemented, this is a followup cleanup.
Ref http://open.silverstripe.org/ticket/7337
Functionality that affects the values in the form better fits in
updateFromEditor function, where we expect the form to be modified.
Redraw should only affect visibility parameters.
Also added a more robust reset code, so we can always expect to get at
least a clean form, and re-added missing "target" checkbox.
Returning a link type "internal" in the situation when no link has been
detected is confusing and makes it hard to know downstream if the link
was detected or not. Switched that to null.
Also added target option to file downloads, as we don't currently have a
mechanism to default this field to "yes" for files.
When adding media via the HtmlEditorField dialog, the value of the URL field wasnt being validated. Youd get different errors depending on if the field was empty
or if it had text, but it didnt look like an absolute URL to HtmlEditorField#viewfile.
This adds some javascript validation to make the text field look like a URL field
IE contentEditable carets and selection boxes show on top of any elements, interfering with HtmlEditorFields dialogs.
This fixes that by storing the selection prior to opening the dialog, then unselecting everything. On dialog close the
selection is restored
HTML in tree nodes is already used to render page icons via SiteTree->TreeTitle.
In order to select the initial value correctly via HTML5 data attributes,
we need to encode any HTML values.
* Use jquery ui accordion for the field, and implemented an admin theme.
* Made the setting of configuration consistent with other form fields.
* ToggleComposteField->startClosed() has been deprecated in favour of
setStartClosed().
* Removed public access to the heading level, instead use getHeadingLevel()
or setHeadingLevel().
* Add arrows back to edit-all toggle button
* Don't show dimensions if the item being inserted doesn't have them.
* Set pop-up windows to be a percentage of the window height for better
use of space
* Fix broken fieldholdersmall styling within files edit
* Add placeholder if no preview
*Take out minFileSize so upload will work on Android phones
* Replaced cancel/delete button in files area
* Consolidated Image upload styles with AssetUpload styles
* Changed name of step 2 in image upload
* Made image editing hidden by default, so multiple files can be seen,
and added ability top open and close
* Tweaked styles in on page upload field (status colour and file name
width)
---
MINOR: SCSS refactoring
1. Refactored some gridfield styles to enable reuse (created a mixin file to hold mixins that generate specific css objects/elements).
2. Made some scss comments use // so they wouldnt appear in generated css
ENHANCEMENT: Gridfield usability (fixes 7215)
1. Modified gridfield to use default colours
2. Added ability to show and hide the filter
3. Design changes to icons used
4. Gridfield template fixes: Took out broken mark-up from templates (spans were being inserted inside spans), and adjusted styles. Added extra class to template
5. Added "filter by ..." placeholder text to input fields
Conflicts:
css/GridField.css
1. Modified gridfield to use default colours
2. Added ability to show and hide the filter
3. Design changes to icons used
4. Gridfield template fixes: Took out broken mark-up from templates
(spans were being inserted inside spans), and adjusted styles. Added
extra class to template
5. Added "filter by ..." placeholder text to input fields
---
These are some enhancements + tweaks I made as part of getting the advanced workflow module running in SS3:
* Added a readonly view button and action to GridField.
* Made LeftAndMain::getResponseNegotiator() public so CMS extensions can use it to generate responses.
* Fixed top tab background, made text more readable (http://i.imgur.com/yDmmY.png).
* Allow fields in the CMS to not be change tracked using ".no-change-track".
* Made all icons 16x16 (some were different sizes, being cut off), and allow them without .ui-state-default.
* Fixed ToggleCompositeField and tweaked field styling.
Add title text to all status messages
Make room for the error message details by expanding the name area in
the file details
Fix up changes status to work with selects
Fixed the calculation of height for the upload (non AssetUploads) area
so that the save button would show. Took off the min-height, as this
will cause UI issues when there are multiple files open for editing.
---
The two bug fixes impact on the file area, but have wider reach.
BUGFIX: Colour Adjustments
Change the constructive button colour to match the colour used in the designs, and fix up calculations to produce the correct button colour.
BUGFIX: IE Colours
Replace hard coded colours in IE with variables, and refactor code so that shared IE7 and IE8 fixes are in one place.
ENHANCEMENT: UI Changes to FileUpload Area (TRAC-7219)
1. Add arrows to edit dropdowns
2. Adjust lightened fields so they dont look like input boxes, and fix rgba colours
3. Add ability to click file names to edit
4. Add feedback when edit button is hovered
5. Add feedback if a file has been opened for editing and shut again (saved changes, unsaved changes, unchanged)
6. Add ability to open and close all files to edit them all at once
7. Add overall feedback for file uploads, and fix NaN error
8. Fix up area to match design
9. Fix error messages so they fit in the provided space
10. Fix case where a single uploaded file errors
---
Ensure the lazy loaded form inside htmleditorfield-dialog is redrawn when lazy loaded. This fixes the initial state for the insert link dialog form.
Also ensure the link form uses "internal" as the default, so the initial state doesnt show all fields, just those associated with the first radio option "internal".
This also fixes http://open.silverstripe.org/ticket/7273.
1. Add arrows to edit dropdowns
2. Adjust lightened fields so they don't look like input boxes, and fix
rgba colours
3. Add ability to click file names to edit
4. Add feedback when edit button is hovered
5. Add feedback if a file has been opened for editing and shut again
(saved changes, unsaved changes, unchanged)
6. Add ability to open and close all files to edit them all at once
7. Add overall feedback for file uploads, and fix NaN error
8. Fix up area to match design
9. Fix error messages so they fit in the provided space
10. Fix case where a single uploaded file errors