Commit Graph

92 Commits (fc41ea7a4381274d99cd051761ac7fa9e721222d)

Author SHA1 Message Date
Brett Zamir 404911827e - Linting (ESLint): Apply new rules ("fixme"->"todo"; prefer regex literals; defaults at end)
- Optimization: Image size
- npm: Bump devDeps (Babel/eslint/rollup-related; imageoptim, testcafe)
2019-09-20 12:40:31 +08:00
Brett Zamir 2e5c7557a9 - Breaking change: `loadSvgString` now returns a `Promise` rather than accepting a callback
- Breaking change: Treat callbacks to `editor.ready` as Promises, only resolving after all resolve
- Breaking change: Make `editor.runCallbacks` return a `Promise` which resolves upon all callbacks resolving
- Breaking change: Require `npx` (used with `babel-node`) to allow Node files
  for HTML building and JSDoc type checking to be expressed as ESM.
- Breaking change: `addExtension` now throws upon a repeated attempt to add an already-added extension
- Breaking change (storage preference cookies): Namespace the cookie as "svgeditstore" instead of just "store"
- Breaking change (API): Remove `svgCanvas.rasterExport` fourth (callback) argument, collapsing fifth (options) to fourth
- Breaking change (API): Remove `svgCanvas.exportPDF` third (callback) argument
- Breaking change (API): `editor/contextmenu.js` `add` now throws instead of giving a console error only upon detecting a bad menuitem or preexisting context menu
- Breaking change (API): Remove `svgCanvas.embedImage` second (callback) argument
- Breaking change (API): Make `getHelpXML` a class instead of instance method of `RGBColor`
- Breaking change (internal API): Refactor `dbox` (and `alert`/`confirm`/`process`/`prompt`/`select`) to avoid a callback argument in favor of return a Promise
- Fix: Avoid running in extension `langReady` multiple times or serially
- Enhancement (API): Add svgCanvas.runExtension to run just one extension and add `nameFilter` callback to `runExtensions`
- Enhancement (API): Supply `$` (our wrapped jQuery) to extensions so can use its plugins, e.g., dbox with its `alert`
- Enhancement: Use alert dialog in place of `alert` in webappfind
- Enhancement: `editor.ready` now returns a Promise resolving when all callbacks have resolved
- Enhancement: Allow `noAlert` option as part of second argument to `loadSvgString` (and `loadFromURL` and `loadFromDataURI`) to avoid UI alert (and trigger promise rejection)
- Enhancement: Make `dbox` as a separate module for alert, prompt, etc. dialogs
- Refactoring: Internal `PaintBox` as class; other misc. tweaks; no bitwise in canvg
- Linting (ESLint): Further linting changes (for editor); rename `.eslintrc` -> `.eslintrc.json` per recommendation
- Optimization: Recompress images (imageoptim-cli updated)
- npm: Update devDeps
- npm: Bump to 4.0.0
2018-11-16 12:48:23 +08:00
Brett Zamir acb57c1609 - Fix: Add images (and references) for fallback (#135)
- Fix (canvg): blur export fix
- i18n (Chinese): A few fixes (#135)
- Optimize: Further image optimizing
- Refactoring: Avoid custom JS substitution syntax
- Refactoring: Reorder default extension list
2018-07-31 00:18:39 -07:00
Brett Zamir ae2394f086 (INCOMPLETE: ES6 Module conversion and linting)
- Breaking change: Require `new` with `EmbeddedSVGEdit` (allows us to use `class` internally)
- Breaking change: If `svgcanvas.setUiStrings` must now be called if not using editor in order
    to get strings (for sake of i18n) (and if using path.js alone, must also have its `setUiStrings` called)
- Breaking change (ext-overview-window): Avoid global `overviewWindowGlobals`
- Breaking change (ext-imagelib): Change to object-based encoding for namespacing of
    messages (though keep stringifying/parsing ourselves until we remove IE9 support)
- Breaking change: Rename `jquery.js` to `jquery.min.js`
- Breaking change: Remove `scoped` attribute from `style`; it is now deprecated and
    obsolete; also move to head (after other stylesheets)
- Enhancement: Make SpinButton plugin independent of SVGEdit via
    generic state object for tool_scale
- Enhancement: Remove now unused Python l10n scripts (#238)
- Enhancement: ES6 Modules (including jQuery plugins but not jQuery)
- Enhancement: Further JSDoc (incomplete)
- Enhancement (Optimization): Compress images using imageoptim (and add
    npm script) (per #215)
- Fix: i18nize path.js strings and canvas notifications
- Fix: Attempt i18n for ext-markers
- Refactoring (ext-storage): Move locale info to own file imported by the extension (toward modularity; still should be split into separate files by language and *dynamically* imported, but we'll wait for better `import` support to refactor this)
- Refactoring: For imagelib, add local jQuery copy (using old 1.4.4 as had
    been using from server)
- Refactoring: For MathJax, add local copy (using old 2.3 as had been using from
    server); server had not been working
- Refactoring: Remove `use strict` (implicit in modules)
- Refactoring: Remove trailing whitespace, fix some code within comments
- Refactoring: Expect `jQuery` global rather than `$` for better modularity
    (also to adapt line later once available via `import`)
- Refactoring: Prefer `const` (and then `let`)
- Refactoring: Add block scope keywords closer to first block in which they appear
- Refactoring: Use ES6 `class`
- Refactoring `$.isArray` -> `Array.isArray` and avoid some other jQuery core methods
    with simple VanillaJS replacements
- Refactoring: Use abbreviated object property syntax
- Refactoring: Object destructuring
- Refactoring: Remove `uiStrings` contents in svg-editor.js (obtains from locale)
- Refactoring: Add favicon to embedded API file
- Refactoring: Use arrow functions for brief functions (incomplete)
- Refactoring: Use `Array.prototype.includes`/`String.prototype.includes`;
    `String.prototype.startsWith`, `String.prototype.trim`
- Refactoring: Remove now unnecessary svgutils do/while resetting of variables
- Refactoring: Use shorthand methods for object literals (avoid ": function")
- Refactoring: Avoid quoting object property keys where unnecessary
- Refactoring: Just do truthy/falsey check for lengths in place of comparison to 0
- Refactoring (Testing): Avoid jQuery usage within most test files (defer script,
    also in preparation for future switch to ES6 modules for tests)
- Refactoring: Make jpicker variable declaration indent bearable
- Refactoring (Linting): Finish svgcanvas.js
- Docs: Mention in comment no longer an entry file as before
- Docs: Migrate old config, extensions, and FAQ docs
- Licensing: Indicate MIT is license type of rgbcolor; rename/add license file name for
    jgraduate and screencast to reflect type (Apache 2.0); rename file to reflect it
    contains license information (of type MIT) for Raphael icons
2018-05-22 18:02:57 +08:00
Brett Zamir 7cf976cfb8 - Fix (Locale): Remove bad characters in Persian (fa) file
- Linting (ESLint): Locale files
- Docs: Fix code comment
- Remove BOM from documents (@drsassafras #237)
2018-05-20 15:04:11 +08:00
Brett Zamir 52353c6321 - Further convert tabs -> 2 spaces in JS code comments (except in test performance
file where used for alignment though use tab escape within JS), CSS
    (including comments), PHP, SVG, JSON, XUL
- Remove extra spaces in svgcanvas.js, ext-connector.js
2018-05-18 14:41:43 +08:00
Brett Zamir f21d41a231 - Linting (ESLint): Use two spaces for indent
- Update links in commented out copyright section of editor, link in screencast, and within SVG file comments (created with SVG-edit should refer to current URL)
2018-05-18 14:05:52 +08:00
Brett Zamir dc6ab72480 - Update Opera and jQuery links
- Use `https://` (fix #172), including in prompt for URL and relevant code comments (where available and naturally not on namespaces)
- Comment out broken link in svg-editor.html
- Trailing space
2018-05-18 13:48:47 +08:00
codedread e38fbc75c7 Remove un-maintained wave code 2018-05-17 21:19:40 -07:00
Brett Zamir 62e7afd659 Allow for "Make (hyper)link" tooltip to show through
git-svn-id: http://svg-edit.googlecode.com/svn/trunk@2688 eee81c28-f429-11dd-99c0-75d572ba1ddd
2014-02-11 02:20:19 +00:00
Brett Zamir d63ed88e25 Rename PNG files accordingly
git-svn-id: http://svg-edit.googlecode.com/svn/trunk@2687 eee81c28-f429-11dd-99c0-75d572ba1ddd
2014-02-11 02:03:54 +00:00
Brett Zamir 74810573b2 Change group to group_elements (though keep duplicate group under old name in case it is supposed to have a different function)
git-svn-id: http://svg-edit.googlecode.com/svn/trunk@2686 eee81c28-f429-11dd-99c0-75d572ba1ddd
2014-02-11 01:58:57 +00:00
Alexis Deveria aafe843485 Fixed Issue 123: Support for <a> element to make elements link to URLs
git-svn-id: http://svg-edit.googlecode.com/svn/trunk@1878 eee81c28-f429-11dd-99c0-75d572ba1ddd
2010-12-01 17:54:11 +00:00
Alexis Deveria 9df823863a Made icons work in IE9 (with a few minor bugs)
git-svn-id: http://svg-edit.googlecode.com/svn/trunk@1680 eee81c28-f429-11dd-99c0-75d572ba1ddd
2010-08-25 15:10:43 +00:00
Alexis Deveria 8345aa43d1 Fixed issue 226 and issue 393, allowing the cloning and merging of layers
git-svn-id: http://svg-edit.googlecode.com/svn/trunk@1672 eee81c28-f429-11dd-99c0-75d572ba1ddd
2010-08-19 18:30:19 +00:00
Alexis Deveria 35ac12a3c9 Made all imported SVGs be placed in the defs with corresponding use elements, added button to convert a use elem to its reference element. Also fixed some minor bugs.
git-svn-id: http://svg-edit.googlecode.com/svn/trunk@1649 eee81c28-f429-11dd-99c0-75d572ba1ddd
2010-07-29 15:09:49 +00:00
Alexis Deveria da474c6232 Optimized icons a little, updated powered by note to RC1
git-svn-id: http://svg-edit.googlecode.com/svn/trunk@1591 eee81c28-f429-11dd-99c0-75d572ba1ddd
2010-06-09 13:47:19 +00:00
Jeff Schiller 2513923d61 Fix Issue 555: New icons for add/delete path nodes from wschleter
git-svn-id: http://svg-edit.googlecode.com/svn/trunk@1574 eee81c28-f429-11dd-99c0-75d572ba1ddd
2010-05-21 22:19:19 +00:00
Jeff Schiller bc70273eb2 Remove various 'Layer 1' titles which cause tooltips in inappropriate places
git-svn-id: http://svg-edit.googlecode.com/svn/trunk@1535 eee81c28-f429-11dd-99c0-75d572ba1ddd
2010-04-21 16:07:56 +00:00
Alexis Deveria afb7ef00bb Made some minor code optimization, added more icon labels (blur by Christian Tzurcanu)
git-svn-id: http://svg-edit.googlecode.com/svn/trunk@1530 eee81c28-f429-11dd-99c0-75d572ba1ddd
2010-04-20 15:53:19 +00:00
Alexis Deveria 2103595301 Converted more text labels to icons. Also made input boxes lose focus on mousedown in workarea
git-svn-id: http://svg-edit.googlecode.com/svn/trunk@1529 eee81c28-f429-11dd-99c0-75d572ba1ddd
2010-04-20 13:21:51 +00:00
Alexis Deveria 91b033a470 Fixed issue 135: Missing the ability to align a single object (relative to page). Also started converting labels to icons
git-svn-id: http://svg-edit.googlecode.com/svn/trunk@1526 eee81c28-f429-11dd-99c0-75d572ba1ddd
2010-04-16 19:16:44 +00:00
Alexis Deveria fee4405d36 Mostly fixed issue 70 (export as PNG option) by using Gabe Lerner's canvg library
git-svn-id: http://svg-edit.googlecode.com/svn/trunk@1521 eee81c28-f429-11dd-99c0-75d572ba1ddd
2010-04-14 17:30:25 +00:00
Jeff Schiller d82910afcd Prevent Layer 1 tooltips on cool new stroke property icons :)
git-svn-id: http://svg-edit.googlecode.com/svn/trunk@1506 eee81c28-f429-11dd-99c0-75d572ba1ddd
2010-04-06 15:57:02 +00:00
Alexis Deveria 6f50b1fdc4 Converted linejoin options to icons
git-svn-id: http://svg-edit.googlecode.com/svn/trunk@1505 eee81c28-f429-11dd-99c0-75d572ba1ddd
2010-04-06 15:53:21 +00:00
Alexis Deveria db3d8f0447 Started conversion of stroke attribute select list to icon list
git-svn-id: http://svg-edit.googlecode.com/svn/trunk@1503 eee81c28-f429-11dd-99c0-75d572ba1ddd
2010-04-05 19:53:14 +00:00
Jeff Schiller 8fac8e144b Fix Issue 522: Layer panel should scroll. Also add 'Dash' label to stroke-dasharray pull-down
git-svn-id: http://svg-edit.googlecode.com/svn/trunk@1502 eee81c28-f429-11dd-99c0-75d572ba1ddd
2010-04-05 05:46:29 +00:00
Alexis Deveria 5c847f6493 Fixed/Integrated support for open/closing subpaths, fixed hidden flyout arrows on smaller icons in Opera, added support for loading extensions in config, uplifted to jQuery 1.4.2 and jQuery UI 1.8
git-svn-id: http://svg-edit.googlecode.com/svn/trunk@1470 eee81c28-f429-11dd-99c0-75d572ba1ddd
2010-03-24 20:13:13 +00:00
Alexis Deveria 750e6456b3 Improved path node deleting behaviour, added functions to get svgCanvas vars: getContentElem, getRootElem and getSelectedElems
git-svn-id: http://svg-edit.googlecode.com/svn/trunk@1455 eee81c28-f429-11dd-99c0-75d572ba1ddd
2010-03-11 15:27:18 +00:00
Alexis Deveria fde7386d75 Added 'add sub-path' button to pathedit context panel
git-svn-id: http://svg-edit.googlecode.com/svn/trunk@1443 eee81c28-f429-11dd-99c0-75d572ba1ddd
2010-03-03 19:26:09 +00:00
Jeff Schiller b849e29e67 Check in new version of logo
git-svn-id: http://svg-edit.googlecode.com/svn/trunk@1434 eee81c28-f429-11dd-99c0-75d572ba1ddd
2010-02-27 04:36:04 +00:00
Jeff Schiller 37aab7dd8f Added 'Import SVG' menu item and icon - only shows up in Firefox 3.6 and functions identically to Open at the moment
git-svn-id: http://svg-edit.googlecode.com/svn/trunk@1420 eee81c28-f429-11dd-99c0-75d572ba1ddd
2010-02-20 23:38:49 +00:00
Alexis Deveria b1463213e2 Changed logo to one designed by Vadim Makeev
git-svn-id: http://svg-edit.googlecode.com/svn/trunk@1370 eee81c28-f429-11dd-99c0-75d572ba1ddd
2010-02-10 16:37:23 +00:00
Alexis Deveria 06d53a325b Made various fixes/changes, made new icon for connector tool
git-svn-id: http://svg-edit.googlecode.com/svn/trunk@1308 eee81c28-f429-11dd-99c0-75d572ba1ddd
2010-01-29 21:28:46 +00:00
Alexis Deveria 75781771be Started on Issue 310: Move to Plugin Architecture, as well as Issue 200: flowchart (just connector lines for now)
git-svn-id: http://svg-edit.googlecode.com/svn/trunk@1277 eee81c28-f429-11dd-99c0-75d572ba1ddd
2010-01-25 21:22:03 +00:00
Jeff Schiller faa165eb9d Change encoding from Western to UTF-8
git-svn-id: http://svg-edit.googlecode.com/svn/trunk@1201 eee81c28-f429-11dd-99c0-75d572ba1ddd
2010-01-12 20:39:03 +00:00
Jeff Schiller 47fc905409 Add in missing PNG files for fallback rasters
git-svn-id: http://svg-edit.googlecode.com/svn/trunk@1151 eee81c28-f429-11dd-99c0-75d572ba1ddd
2010-01-04 23:22:53 +00:00
Jeff Schiller e96d0db8fd Remove layer name accidentally left in a SVG icon - caused an incorrect tooltip in Opera :)
git-svn-id: http://svg-edit.googlecode.com/svn/trunk@1063 eee81c28-f429-11dd-99c0-75d572ba1ddd
2009-12-18 06:34:13 +00:00
Alexis Deveria d800f4b5f9 Updated control point link icon, fixed issue 344
git-svn-id: http://svg-edit.googlecode.com/svn/trunk@986 eee81c28-f429-11dd-99c0-75d572ba1ddd
2009-12-01 21:23:18 +00:00
Alexis Deveria 5173ad7eea Added option to link curved segment control points in pathedit mode
git-svn-id: http://svg-edit.googlecode.com/svn/trunk@985 eee81c28-f429-11dd-99c0-75d572ba1ddd
2009-12-01 19:26:33 +00:00
Alexis Deveria d5f867f0a8 Fixed issue 68 by adding Convert to Path button, also included Reorient Path button
git-svn-id: http://svg-edit.googlecode.com/svn/trunk@981 eee81c28-f429-11dd-99c0-75d572ba1ddd
2009-11-30 19:14:23 +00:00
Alexis Deveria 5f4caf6c53 Finished up changes to inline image behaviour, many fixes from last update
git-svn-id: http://svg-edit.googlecode.com/svn/trunk@953 eee81c28-f429-11dd-99c0-75d572ba1ddd
2009-11-18 16:50:25 +00:00
Alexis Deveria 237fd96b0f Changed order of circle&ellipse and square&rect as per issue 179
git-svn-id: http://svg-edit.googlecode.com/svn/branches/transformlist@927 eee81c28-f429-11dd-99c0-75d572ba1ddd
2009-11-10 19:16:45 +00:00
Alexis Deveria 9cb650119f Fixed freehand rect icon
git-svn-id: http://svg-edit.googlecode.com/svn/branches/transformlist@922 eee81c28-f429-11dd-99c0-75d572ba1ddd
2009-11-09 21:21:45 +00:00
Alexis Deveria 08f80ac7e9 Fixed node select icon
git-svn-id: http://svg-edit.googlecode.com/svn/branches/transformlist@919 eee81c28-f429-11dd-99c0-75d572ba1ddd
2009-11-09 20:29:01 +00:00
Alexis Deveria c4b5fa1430 Fixed many of the remaining todos for SVG-icons
git-svn-id: http://svg-edit.googlecode.com/svn/branches/transformlist@913 eee81c28-f429-11dd-99c0-75d572ba1ddd
2009-11-06 21:24:00 +00:00
Alexis Deveria 3301054326 Made several fixes and improments to SVG icons page
git-svn-id: http://svg-edit.googlecode.com/svn/branches/transformlist@912 eee81c28-f429-11dd-99c0-75d572ba1ddd
2009-11-05 21:25:33 +00:00
Alexis Deveria dd602d8203 Adding svg_edit_icons.svgz file for testing
git-svn-id: http://svg-edit.googlecode.com/svn/branches/transformlist@909 eee81c28-f429-11dd-99c0-75d572ba1ddd
2009-11-04 21:23:40 +00:00
Alexis Deveria 59d8b00827 SVG icon page: Added more SVG icons, made flyouts work (not on Opera), set all fallback icons, improved UI on resize
git-svn-id: http://svg-edit.googlecode.com/svn/branches/transformlist@908 eee81c28-f429-11dd-99c0-75d572ba1ddd
2009-11-04 21:00:21 +00:00
Alexis Deveria 20d7b92b58 Added more SVG icons, added experimental option to change icon size, fixed clone offset on zoom
git-svn-id: http://svg-edit.googlecode.com/svn/trunk@889 eee81c28-f429-11dd-99c0-75d572ba1ddd
2009-10-30 19:39:33 +00:00