svgedit-pl 7.3.6 → 7.3.11

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (153) hide show
  1. package/dist/editor/Editor.js +2 -2
  2. package/dist/editor/Editor.js.map +1 -1
  3. package/dist/editor/extensions/ext-opensave/ext-opensave.js +1 -1
  4. package/dist/editor/extensions/ext-opensave/ext-opensave.js.map +1 -1
  5. package/dist/editor/extensions/ext-panning/ext-panning.js +1 -1
  6. package/dist/editor/extensions/ext-panning/ext-panning.js.map +1 -1
  7. package/dist/editor/extensions/ext-storage/ext-storage.js +1 -1
  8. package/dist/editor/extensions/ext-storage/ext-storage.js.map +1 -1
  9. package/dist/editor/iife-Editor.js +2 -2
  10. package/dist/editor/iife-Editor.js.map +1 -1
  11. package/dist/editor/xdomain-Editor.js +2 -2
  12. package/dist/editor/xdomain-Editor.js.map +1 -1
  13. package/docs/jsdoc/BottomPanel.html +1 -1
  14. package/docs/jsdoc/ConfigObj.js.html +11 -11
  15. package/docs/jsdoc/Dropdown.html +1 -1
  16. package/docs/jsdoc/Editor.js.html +54 -55
  17. package/docs/jsdoc/EditorStartup.html +5 -5
  18. package/docs/jsdoc/EditorStartup.js.html +12 -11
  19. package/docs/jsdoc/ElixMenuButton.html +1 -1
  20. package/docs/jsdoc/ElixNumberSpinBox.html +1 -1
  21. package/docs/jsdoc/ExplorerButton.html +1 -1
  22. package/docs/jsdoc/FlyingButton.html +1 -1
  23. package/docs/jsdoc/LayersPanel.html +1 -1
  24. package/docs/jsdoc/LeftPanel.html +1 -1
  25. package/docs/jsdoc/MainMenu.html +1 -1
  26. package/docs/jsdoc/MainMenu.js.html +12 -12
  27. package/docs/jsdoc/NumberSpinBox.html +1 -1
  28. package/docs/jsdoc/PaintBox.html +1 -1
  29. package/docs/jsdoc/PlainNumberSpinBox.html +1 -1
  30. package/docs/jsdoc/Rulers.html +1 -1
  31. package/docs/jsdoc/Rulers.js.html +1 -1
  32. package/docs/jsdoc/SEInput.html +1 -1
  33. package/docs/jsdoc/SEPalette.html +1 -1
  34. package/docs/jsdoc/SESpinInput.html +1 -1
  35. package/docs/jsdoc/SeCMenuDialog.html +1 -1
  36. package/docs/jsdoc/SeCMenuLayerDialog.html +1 -1
  37. package/docs/jsdoc/SeColorPicker.html +1 -1
  38. package/docs/jsdoc/SeEditPrefsDialog.html +1 -1
  39. package/docs/jsdoc/SeExportDialog.html +1 -1
  40. package/docs/jsdoc/SeImgPropDialog.html +1 -1
  41. package/docs/jsdoc/SeList.html +1 -1
  42. package/docs/jsdoc/SeMenu.html +1 -1
  43. package/docs/jsdoc/SeMenuItem.html +1 -1
  44. package/docs/jsdoc/SePlainAlertDialog.html +1 -1
  45. package/docs/jsdoc/SePlainBorderButton.html +1 -1
  46. package/docs/jsdoc/SePromptDialog.html +1 -1
  47. package/docs/jsdoc/SeStorageDialog.html +1 -1
  48. package/docs/jsdoc/SeSvgSourceEditorDialog.html +1 -1
  49. package/docs/jsdoc/SeText.html +1 -1
  50. package/docs/jsdoc/ToolButton.html +1 -1
  51. package/docs/jsdoc/TopPanel.html +1 -1
  52. package/docs/jsdoc/components_PaintBox.js.html +1 -1
  53. package/docs/jsdoc/components_jgraduate_ColorValuePicker.js.html +1 -1
  54. package/docs/jsdoc/components_jgraduate_Slider.js.html +1 -1
  55. package/docs/jsdoc/components_jgraduate_jQuery.jGraduate.js.html +1 -1
  56. package/docs/jsdoc/components_jgraduate_jQuery.jPicker.js.html +1 -1
  57. package/docs/jsdoc/components_seButton.js.html +1 -1
  58. package/docs/jsdoc/components_seColorPicker.js.html +1 -1
  59. package/docs/jsdoc/components_seDropdown.js.html +1 -1
  60. package/docs/jsdoc/components_seExplorerButton.js.html +1 -1
  61. package/docs/jsdoc/components_seFlyingButton.js.html +1 -1
  62. package/docs/jsdoc/components_seInput.js.html +1 -1
  63. package/docs/jsdoc/components_seList.js.html +1 -1
  64. package/docs/jsdoc/components_seListItem.js.html +1 -1
  65. package/docs/jsdoc/components_seMenu.js.html +1 -1
  66. package/docs/jsdoc/components_seMenuItem.js.html +1 -1
  67. package/docs/jsdoc/components_sePalette.js.html +1 -1
  68. package/docs/jsdoc/components_sePlainBorderButton.js.html +1 -1
  69. package/docs/jsdoc/components_sePlainMenuButton.js.html +1 -1
  70. package/docs/jsdoc/components_seSelect.js.html +1 -1
  71. package/docs/jsdoc/components_seSpinInput.js.html +1 -1
  72. package/docs/jsdoc/components_seText.js.html +1 -1
  73. package/docs/jsdoc/components_seZoom.js.html +1 -1
  74. package/docs/jsdoc/configObj.html +1 -1
  75. package/docs/jsdoc/contextmenu.js.html +1 -1
  76. package/docs/jsdoc/dialogs_SePlainAlertDialog.js.html +1 -1
  77. package/docs/jsdoc/dialogs_cmenuDialog.js.html +1 -1
  78. package/docs/jsdoc/dialogs_cmenuLayersDialog.js.html +1 -1
  79. package/docs/jsdoc/dialogs_editorPreferencesDialog.js.html +1 -1
  80. package/docs/jsdoc/dialogs_exportDialog.js.html +1 -1
  81. package/docs/jsdoc/dialogs_imagePropertiesDialog.js.html +1 -1
  82. package/docs/jsdoc/dialogs_se-elix_define_NumberSpinBox.js.html +1 -1
  83. package/docs/jsdoc/dialogs_se-elix_src_base_NumberSpinBox.js.html +1 -1
  84. package/docs/jsdoc/dialogs_se-elix_src_plain_PlainNumberSpinBox.js.html +1 -1
  85. package/docs/jsdoc/dialogs_sePromptDialog.js.html +1 -1
  86. package/docs/jsdoc/dialogs_svgSourceDialog.js.html +1 -1
  87. package/docs/jsdoc/extensions_ext-connector_ext-connector.js.html +1 -1
  88. package/docs/jsdoc/extensions_ext-eyedropper_ext-eyedropper.js.html +1 -1
  89. package/docs/jsdoc/extensions_ext-grid_ext-grid.js.html +1 -1
  90. package/docs/jsdoc/extensions_ext-helloworld_ext-helloworld.js.html +1 -1
  91. package/docs/jsdoc/extensions_ext-layer_view_ext-layer_view.js.html +1 -1
  92. package/docs/jsdoc/extensions_ext-markers_ext-markers.js.html +1 -1
  93. package/docs/jsdoc/extensions_ext-opensave_ext-opensave.js.html +5 -5
  94. package/docs/jsdoc/extensions_ext-overview_window_ext-overview_window.js.html +1 -1
  95. package/docs/jsdoc/extensions_ext-panning_ext-panning.js.html +6 -6
  96. package/docs/jsdoc/extensions_ext-polystar_ext-polystar.js.html +1 -1
  97. package/docs/jsdoc/extensions_ext-shapes_ext-shapes.js.html +1 -1
  98. package/docs/jsdoc/extensions_ext-storage_ext-storage.js.html +26 -7
  99. package/docs/jsdoc/extensions_ext-storage_storageDialog.js.html +8 -8
  100. package/docs/jsdoc/external-JamilihArray.html +1 -1
  101. package/docs/jsdoc/external-Math.html +1 -1
  102. package/docs/jsdoc/external-Window.html +1 -1
  103. package/docs/jsdoc/external-jQuery.fn.$.fn.jPicker.defaults.html +1 -1
  104. package/docs/jsdoc/external-jQuery.fn.exports.jPickerMethod.html +1 -1
  105. package/docs/jsdoc/external-jQuery.fn.html +1 -1
  106. package/docs/jsdoc/external-jQuery.fn.jGraduateDefaults.html +1 -1
  107. package/docs/jsdoc/external-jQuery.fn.jGraduateDefaults.images.html +1 -1
  108. package/docs/jsdoc/external-jQuery.fn.jGraduateDefaults.window.html +1 -1
  109. package/docs/jsdoc/external-jQuery.html +1 -1
  110. package/docs/jsdoc/external-jQuery.jGraduate.Paint.html +1 -1
  111. package/docs/jsdoc/external-jQuery.jGraduate.html +1 -1
  112. package/docs/jsdoc/external-jQuery.jPicker.Color.html +1 -1
  113. package/docs/jsdoc/external-jQuery.jPicker.ColorMethods.html +1 -1
  114. package/docs/jsdoc/external-jQuery.jPicker.html +1 -1
  115. package/docs/jsdoc/global.html +1 -1
  116. package/docs/jsdoc/index.html +1 -1
  117. package/docs/jsdoc/locale.js.html +1 -1
  118. package/docs/jsdoc/module-SVGEditor-Editor.html +30 -30
  119. package/docs/jsdoc/module-SVGEditor.Config.html +1 -1
  120. package/docs/jsdoc/module-SVGEditor.Prefs.html +1 -1
  121. package/docs/jsdoc/module-SVGEditor.html +3 -3
  122. package/docs/jsdoc/module-SVGthis.CustomHandler.html +1 -1
  123. package/docs/jsdoc/module-contextmenu.html +1 -1
  124. package/docs/jsdoc/module-jGraduate.html +1 -1
  125. package/docs/jsdoc/module-jPicker.html +1 -1
  126. package/docs/jsdoc/module-jPicker.module.exports.html +1 -1
  127. package/docs/jsdoc/module-locale.LocaleEditorInit.html +1 -1
  128. package/docs/jsdoc/module-locale.html +1 -1
  129. package/docs/jsdoc/module.exports.html +1 -1
  130. package/docs/jsdoc/module.exports_module.exports.html +1 -1
  131. package/docs/jsdoc/panels_BottomPanel.js.html +1 -1
  132. package/docs/jsdoc/panels_LayersPanel.js.html +1 -1
  133. package/docs/jsdoc/panels_LeftPanel.js.html +1 -1
  134. package/docs/jsdoc/panels_TopPanel.js.html +1 -1
  135. package/docs/jsdoc/tutorial-CanvasAPI.html +1 -1
  136. package/docs/jsdoc/tutorial-ConfigOptions.html +1 -1
  137. package/docs/jsdoc/tutorial-Editor.html +1 -1
  138. package/docs/jsdoc/tutorial-EditorAPI.html +1 -1
  139. package/docs/jsdoc/tutorial-Events.html +1 -1
  140. package/docs/jsdoc/tutorial-ExtensionDocs.html +1 -1
  141. package/docs/jsdoc/tutorial-FrequentlyAskedQuestions.html +1 -1
  142. package/docs/jsdoc/tutorial-LocaleDocs.html +1 -1
  143. package/docs/jsdoc/typedefs.js.html +1 -1
  144. package/package.json +1 -1
  145. package/src/editor/ConfigObj.js +10 -10
  146. package/src/editor/Editor.js +53 -54
  147. package/src/editor/EditorStartup.js +11 -10
  148. package/src/editor/MainMenu.js +11 -11
  149. package/src/editor/extensions/ext-opensave/ext-opensave.js +4 -4
  150. package/src/editor/extensions/ext-panning/ext-panning.js +5 -5
  151. package/src/editor/extensions/ext-storage/ext-storage.js +25 -6
  152. package/src/editor/extensions/ext-storage/storageDialog.js +7 -7
  153. package/src/editor/panels/TopPanel.html +1 -1
@@ -61,7 +61,7 @@ const replaceStoragePrompt = val => {
61
61
 
62
62
  export default {
63
63
  name: 'storage',
64
- init () {
64
+ init() {
65
65
  const svgEditor = this
66
66
  const { svgCanvas, storage } = svgEditor
67
67
 
@@ -96,7 +96,7 @@ export default {
96
96
  const cached = storage.getItem(key)
97
97
  if (cached) {
98
98
  svgEditor.loadFromString(cached)
99
- const name = storage.getItem(`title-${key}`) ?? 'untitled.svg'
99
+ const name = storage.getItem(`title-${key}`) ?? 'bez_tytulu.svg'
100
100
  svgEditor.topPanel.updateTitle(name)
101
101
  svgEditor.layersPanel.populateLayers()
102
102
  }
@@ -222,7 +222,7 @@ export default {
222
222
  let loaded = false
223
223
  return {
224
224
  name: 'storage',
225
- callback () {
225
+ callback() {
226
226
  const storagePrompt = new URL(top.location).searchParams.get(
227
227
  'storagePrompt'
228
228
  )
@@ -258,9 +258,28 @@ export default {
258
258
  // Open select-with-checkbox dialog
259
259
  // From svg-editor.js
260
260
  svgEditor.storagePromptState = 'waiting'
261
- const $storageDialog = document.getElementById('se-storage-dialog')
262
- $storageDialog.setAttribute('dialog', 'open')
263
- $storageDialog.setAttribute('storage', options)
261
+ const $storageDialog = document.getElementById('se-storage-dialog');
262
+
263
+ const forceSavePreferencesLocally = true;
264
+
265
+ if (forceSavePreferencesLocally) {
266
+ console.log('will dispatch', $storageDialog)
267
+ $storageDialog.dispatchEvent(
268
+ new CustomEvent(
269
+ 'change',
270
+ {
271
+ detail: {
272
+ "trigger": "ok",
273
+ "select": "prefsOnly",
274
+ "checkbox": true
275
+ }
276
+ }
277
+ )
278
+ )
279
+ } else {
280
+ $storageDialog.setAttribute('dialog', 'open');
281
+ $storageDialog.setAttribute('storage', options);
282
+ }
264
283
  } else if (!noStorageOnLoad || forceStorage) {
265
284
  setupBeforeUnloadListener()
266
285
  }
@@ -10,7 +10,7 @@ export class SeStorageDialog extends HTMLElement {
10
10
  /**
11
11
  * @function constructor
12
12
  */
13
- constructor () {
13
+ constructor() {
14
14
  super()
15
15
  // create the shadowDom and insert the template
16
16
  this._shadowRoot = this.attachShadow({ mode: 'open' })
@@ -28,7 +28,7 @@ export class SeStorageDialog extends HTMLElement {
28
28
  * @param {any} name
29
29
  * @returns {void}
30
30
  */
31
- init (i18next) {
31
+ init(i18next) {
32
32
  this.setAttribute('common-ok', i18next.t('common.ok'))
33
33
  this.setAttribute('common-cancel', i18next.t('common.cancel'))
34
34
  this.setAttribute('notify-editor_pref_msg', i18next.t('notification.editorPreferencesMsg'))
@@ -43,7 +43,7 @@ export class SeStorageDialog extends HTMLElement {
43
43
  * @function observedAttributes
44
44
  * @returns {any} observed
45
45
  */
46
- static get observedAttributes () {
46
+ static get observedAttributes() {
47
47
  return ['dialog', 'storage', 'common-ok', 'common-cancel', 'notify-editor_pref_msg', 'properties-prefs_and_content', 'tools-remember_this_choice', 'tools-remember_this_choice_title', 'properties-prefs_only', 'properties-no_prefs_or_content']
48
48
  }
49
49
 
@@ -54,7 +54,7 @@ export class SeStorageDialog extends HTMLElement {
54
54
  * @param {string} newValue
55
55
  * @returns {void}
56
56
  */
57
- attributeChangedCallback (name, oldValue, newValue) {
57
+ attributeChangedCallback(name, oldValue, newValue) {
58
58
  let node
59
59
  switch (name) {
60
60
  case 'dialog':
@@ -111,7 +111,7 @@ export class SeStorageDialog extends HTMLElement {
111
111
  * @function get
112
112
  * @returns {any}
113
113
  */
114
- get dialog () {
114
+ get dialog() {
115
115
  return this.getAttribute('dialog')
116
116
  }
117
117
 
@@ -119,7 +119,7 @@ export class SeStorageDialog extends HTMLElement {
119
119
  * @function set
120
120
  * @returns {void}
121
121
  */
122
- set dialog (value) {
122
+ set dialog(value) {
123
123
  this.setAttribute('dialog', value)
124
124
  }
125
125
 
@@ -127,7 +127,7 @@ export class SeStorageDialog extends HTMLElement {
127
127
  * @function connectedCallback
128
128
  * @returns {void}
129
129
  */
130
- connectedCallback () {
130
+ connectedCallback() {
131
131
  const onSubmitHandler = (e, action) => {
132
132
  const triggerEvent = new CustomEvent('change',
133
133
  {
@@ -1,6 +1,6 @@
1
1
  <div id="tools_top">
2
2
  <div id="title_panel">
3
- <p>untitled.svg</p>
3
+ <p>bez_tytulu.svg</p>
4
4
  </div> <!-- title panel -->
5
5
  <div id="editor_panel">
6
6
  <div class="tool_sep"></div>