@sankhyalabs/sankhyablocks 10.1.0-dev.23 → 10.1.0-dev.24

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 (158) hide show
  1. package/dist/cjs/{ConfigStorage-a4e1e518.js → ConfigStorage-f61eedd2.js} +2 -2
  2. package/dist/cjs/{DataFetcher-0b6aa084.js → DataFetcher-0c830777.js} +2 -2743
  3. package/dist/cjs/{ISave-2c455a77.js → ISave-e1e8ec96.js} +1 -1
  4. package/dist/cjs/ImageUtils-5e3f406b.js +142 -0
  5. package/dist/cjs/{SnkFormConfigManager-b8c81493.js → SnkFormConfigManager-421f3581.js} +2 -2
  6. package/dist/cjs/SnkMessageBuilder-32950342.js +2785 -0
  7. package/dist/cjs/{SnkMultiSelectionListDataSource-03b58f5a.js → SnkMultiSelectionListDataSource-d30a96ef.js} +4 -4
  8. package/dist/cjs/{auth-fetcher-7e7796c9.js → auth-fetcher-761d54c4.js} +1 -1
  9. package/dist/cjs/{dataunit-fetcher-8dffbcdf.js → dataunit-fetcher-86e286bb.js} +3 -2
  10. package/dist/cjs/{form-config-fetcher-5516d68a.js → form-config-fetcher-227b2db2.js} +1 -1
  11. package/dist/cjs/index-1894343a.js +4 -0
  12. package/dist/cjs/loader.cjs.js +1 -1
  13. package/dist/cjs/pesquisa-grid_2.cjs.entry.js +5 -4
  14. package/dist/cjs/sankhyablocks.cjs.js +1 -1
  15. package/dist/cjs/snk-actions-button_9.cjs.entry.js +6 -5
  16. package/dist/cjs/snk-application.cjs.entry.js +8 -7
  17. package/dist/cjs/snk-attach.cjs.entry.js +7 -6
  18. package/dist/cjs/snk-crud.cjs.entry.js +6 -5
  19. package/dist/cjs/snk-data-exporter.cjs.entry.js +6 -5
  20. package/dist/cjs/{snk-data-unit-036ce58c.js → snk-data-unit-c06263da.js} +11 -11
  21. package/dist/cjs/snk-data-unit.cjs.entry.js +4 -3
  22. package/dist/cjs/snk-detail-view.cjs.entry.js +11 -10
  23. package/dist/cjs/snk-filter-bar_4.cjs.entry.js +4 -3
  24. package/dist/cjs/snk-filter-modal-item.cjs.entry.js +4 -3
  25. package/dist/cjs/snk-form-view.cjs.entry.js +56 -2
  26. package/dist/cjs/snk-form_2.cjs.entry.js +5 -4
  27. package/dist/cjs/snk-grid.cjs.entry.js +7 -6
  28. package/dist/cjs/{snk-guides-viewer-164c063e.js → snk-guides-viewer-92dadfa6.js} +9 -8
  29. package/dist/cjs/snk-guides-viewer.cjs.entry.js +8 -7
  30. package/dist/cjs/snk-image-input.cjs.entry.js +148 -0
  31. package/dist/cjs/snk-personalized-filter.cjs.entry.js +4 -3
  32. package/dist/cjs/snk-pesquisa.cjs.entry.js +5 -4
  33. package/dist/cjs/snk-simple-crud.cjs.entry.js +8 -7
  34. package/dist/collection/collection-manifest.json +1 -0
  35. package/dist/collection/components/snk-application/snk-application.js +1 -1
  36. package/dist/collection/components/snk-crud/subcomponents/snk-detail-view/snk-detail-view.js +1 -1
  37. package/dist/collection/components/snk-crud/subcomponents/snk-form-view.js +75 -2
  38. package/dist/collection/components/snk-crud/subcomponents/snk-guides-viewer.js +4 -3
  39. package/dist/collection/components/snk-image-input/snk-image-input.css +3 -0
  40. package/dist/collection/components/snk-image-input/snk-image-input.js +326 -0
  41. package/dist/collection/components/snk-image-input/utils/ImageUtils.js +133 -0
  42. package/dist/collection/lib/message/messageResourceEnUSUtils.js +2 -0
  43. package/dist/collection/lib/message/messageResourceEsESUtils.js +2 -0
  44. package/dist/collection/lib/message/messageResourcePtBRUtils.js +2 -0
  45. package/dist/collection/lib/message/resources/en-us/snk-image-input.msg.js +11 -0
  46. package/dist/collection/lib/message/resources/es-es/snk-image-input.msg.js +11 -0
  47. package/dist/collection/lib/message/resources/pt-br/snk-image-input.msg.js +11 -0
  48. package/dist/components/DataFetcher.js +3 -2743
  49. package/dist/components/SnkMessageBuilder.js +2783 -0
  50. package/dist/components/dataunit-fetcher.js +2 -1
  51. package/dist/components/index.d.ts +1 -0
  52. package/dist/components/index.js +1 -0
  53. package/dist/components/snk-application2.js +2 -1
  54. package/dist/components/snk-attach2.js +2 -1
  55. package/dist/components/snk-crud.js +69 -63
  56. package/dist/components/snk-data-unit2.js +1 -1
  57. package/dist/components/snk-detail-view2.js +100 -87
  58. package/dist/components/snk-form-view2.js +65 -5
  59. package/dist/components/snk-image-input.d.ts +11 -0
  60. package/dist/components/snk-image-input.js +6 -0
  61. package/dist/components/snk-image-input2.js +302 -0
  62. package/dist/esm/{ConfigStorage-39ac8fef.js → ConfigStorage-175813dc.js} +2 -2
  63. package/dist/esm/{DataFetcher-0b9da57d.js → DataFetcher-49594174.js} +3 -2743
  64. package/dist/esm/{ISave-f1c9269b.js → ISave-4bdffce4.js} +1 -1
  65. package/dist/esm/ImageUtils-8fc8d905.js +136 -0
  66. package/dist/esm/{SnkFormConfigManager-a87566c8.js → SnkFormConfigManager-0bda2ef5.js} +2 -2
  67. package/dist/esm/SnkMessageBuilder-1c0fada0.js +2783 -0
  68. package/dist/esm/{SnkMultiSelectionListDataSource-01b3744b.js → SnkMultiSelectionListDataSource-e13b72f7.js} +4 -4
  69. package/dist/esm/{auth-fetcher-acdc1cb4.js → auth-fetcher-62c5abf1.js} +1 -1
  70. package/dist/esm/{dataunit-fetcher-4c312b43.js → dataunit-fetcher-b7a9ef67.js} +2 -1
  71. package/dist/esm/{form-config-fetcher-7cda6254.js → form-config-fetcher-5e29a152.js} +1 -1
  72. package/dist/esm/index-04f73a26.js +4 -0
  73. package/dist/esm/loader.js +1 -1
  74. package/dist/esm/pesquisa-grid_2.entry.js +5 -4
  75. package/dist/esm/sankhyablocks.js +1 -1
  76. package/dist/esm/snk-actions-button_9.entry.js +6 -5
  77. package/dist/esm/snk-application.entry.js +7 -6
  78. package/dist/esm/snk-attach.entry.js +6 -5
  79. package/dist/esm/snk-crud.entry.js +6 -5
  80. package/dist/esm/snk-data-exporter.entry.js +6 -5
  81. package/dist/esm/{snk-data-unit-130021b3.js → snk-data-unit-865a1e27.js} +2 -2
  82. package/dist/esm/snk-data-unit.entry.js +4 -3
  83. package/dist/esm/snk-detail-view.entry.js +9 -8
  84. package/dist/esm/snk-filter-bar_4.entry.js +4 -3
  85. package/dist/esm/snk-filter-modal-item.entry.js +4 -3
  86. package/dist/esm/snk-form-view.entry.js +57 -3
  87. package/dist/esm/snk-form_2.entry.js +5 -4
  88. package/dist/esm/snk-grid.entry.js +7 -6
  89. package/dist/esm/{snk-guides-viewer-3fd18298.js → snk-guides-viewer-2e2f48af.js} +9 -8
  90. package/dist/esm/snk-guides-viewer.entry.js +8 -7
  91. package/dist/esm/snk-image-input.entry.js +144 -0
  92. package/dist/esm/snk-personalized-filter.entry.js +4 -3
  93. package/dist/esm/snk-pesquisa.entry.js +5 -4
  94. package/dist/esm/snk-simple-crud.entry.js +8 -7
  95. package/dist/sankhyablocks/p-0fbd3f2f.entry.js +1 -0
  96. package/dist/sankhyablocks/p-164721f4.entry.js +1 -0
  97. package/dist/sankhyablocks/{p-2ac55a5d.js → p-1d0e4e8f.js} +1 -1
  98. package/dist/sankhyablocks/p-3448ebdc.js +60 -0
  99. package/dist/sankhyablocks/{p-7ee6b1bf.js → p-34d56802.js} +1 -1
  100. package/dist/sankhyablocks/p-36a82166.entry.js +1 -0
  101. package/dist/sankhyablocks/p-3f762af3.entry.js +1 -0
  102. package/dist/sankhyablocks/p-4005bd63.entry.js +1 -0
  103. package/dist/sankhyablocks/p-4ff3b494.js +1 -0
  104. package/dist/sankhyablocks/{p-5e2dffc1.entry.js → p-71ea8d08.entry.js} +2 -2
  105. package/dist/sankhyablocks/p-8bf2a358.entry.js +1 -0
  106. package/dist/sankhyablocks/{p-d714b6ca.js → p-8e5f4851.js} +1 -1
  107. package/dist/sankhyablocks/{p-1f310bc6.js → p-93f4104a.js} +1 -1
  108. package/dist/sankhyablocks/p-abcfff93.entry.js +1 -0
  109. package/dist/sankhyablocks/p-b10e79bb.js +1 -0
  110. package/dist/sankhyablocks/p-bafeda2d.entry.js +1 -0
  111. package/dist/sankhyablocks/{p-48a5c311.js → p-bf37b0e2.js} +2 -2
  112. package/dist/sankhyablocks/p-c5d6717d.entry.js +1 -0
  113. package/dist/sankhyablocks/p-d2581c6b.entry.js +1 -0
  114. package/dist/sankhyablocks/p-d4e3e549.js +1 -0
  115. package/dist/sankhyablocks/p-ddb20d9e.entry.js +1 -0
  116. package/dist/sankhyablocks/p-e19a65a2.js +1 -0
  117. package/dist/sankhyablocks/p-e892ae6c.entry.js +1 -0
  118. package/dist/sankhyablocks/p-e9bbd66b.js +1 -0
  119. package/dist/sankhyablocks/p-e9e9ff1c.entry.js +1 -0
  120. package/dist/sankhyablocks/p-f21109d6.entry.js +1 -0
  121. package/dist/sankhyablocks/p-f455a553.entry.js +1 -0
  122. package/dist/sankhyablocks/p-f61fef9a.entry.js +1 -0
  123. package/dist/sankhyablocks/{p-998a9d6f.js → p-f63e1093.js} +1 -1
  124. package/dist/sankhyablocks/p-fc0736ad.entry.js +1 -0
  125. package/dist/sankhyablocks/sankhyablocks.esm.js +1 -1
  126. package/dist/types/components/snk-application/snk-application.d.ts +1 -1
  127. package/dist/types/components/snk-crud/subcomponents/snk-form-view.d.ts +9 -0
  128. package/dist/types/components/snk-crud/subcomponents/snk-guides-viewer.d.ts +1 -0
  129. package/dist/types/components/snk-image-input/snk-image-input.d.ts +56 -0
  130. package/dist/types/components/snk-image-input/utils/ImageUtils.d.ts +15 -0
  131. package/dist/types/components.d.ts +89 -0
  132. package/dist/types/lib/message/resources/en-us/snk-image-input.msg.d.ts +1 -0
  133. package/dist/types/lib/message/resources/es-es/snk-image-input.msg.d.ts +1 -0
  134. package/dist/types/lib/message/resources/pt-br/snk-image-input.msg.d.ts +1 -0
  135. package/package.json +1 -1
  136. package/react/components.d.ts +1 -0
  137. package/react/components.js +1 -0
  138. package/react/components.js.map +1 -1
  139. package/dist/sankhyablocks/p-12f595a6.entry.js +0 -1
  140. package/dist/sankhyablocks/p-18d66638.entry.js +0 -1
  141. package/dist/sankhyablocks/p-2a33d4cf.entry.js +0 -1
  142. package/dist/sankhyablocks/p-2c6be187.entry.js +0 -1
  143. package/dist/sankhyablocks/p-3a443150.entry.js +0 -1
  144. package/dist/sankhyablocks/p-3b6d8d33.entry.js +0 -1
  145. package/dist/sankhyablocks/p-3db72758.entry.js +0 -1
  146. package/dist/sankhyablocks/p-52691b42.js +0 -1
  147. package/dist/sankhyablocks/p-6768f176.js +0 -1
  148. package/dist/sankhyablocks/p-6d322b0a.js +0 -1
  149. package/dist/sankhyablocks/p-877d9614.entry.js +0 -1
  150. package/dist/sankhyablocks/p-94267a30.entry.js +0 -1
  151. package/dist/sankhyablocks/p-9e4555ab.js +0 -60
  152. package/dist/sankhyablocks/p-acd2ba28.entry.js +0 -1
  153. package/dist/sankhyablocks/p-b533edab.entry.js +0 -1
  154. package/dist/sankhyablocks/p-c2d33fc8.entry.js +0 -1
  155. package/dist/sankhyablocks/p-cd40c8cf.entry.js +0 -1
  156. package/dist/sankhyablocks/p-cd412add.entry.js +0 -1
  157. package/dist/sankhyablocks/p-d6dad5e4.entry.js +0 -1
  158. package/dist/sankhyablocks/p-f8c5395a.entry.js +0 -1
@@ -5,14 +5,15 @@ Object.defineProperty(exports, '__esModule', { value: true });
5
5
  const index = require('./index-1894343a.js');
6
6
  const core = require('@sankhyalabs/core');
7
7
  const PersonalizedFilterUtils = require('./PersonalizedFilterUtils-eccb267a.js');
8
- const ConfigStorage = require('./ConfigStorage-a4e1e518.js');
8
+ const ConfigStorage = require('./ConfigStorage-f61eedd2.js');
9
9
  const utils = require('@sankhyalabs/ezui/dist/collection/utils');
10
10
  const index$1 = require('./index-62760a9c.js');
11
11
  const index$2 = require('./index-f0fe7e6e.js');
12
12
  require('./filter-item-type.enum-a7ffdaa6.js');
13
- require('./form-config-fetcher-5516d68a.js');
14
- require('./DataFetcher-0b6aa084.js');
13
+ require('./form-config-fetcher-227b2db2.js');
14
+ require('./DataFetcher-0c830777.js');
15
15
  require('./PrintUtils-bcaeb82f.js');
16
+ require('./SnkMessageBuilder-32950342.js');
16
17
  require('@sankhyalabs/core/dist/dataunit/metadata/UnitMetadata');
17
18
 
18
19
  const snkPersonalizedFilterCss = ".sc-snk-personalized-filter-h{display:flex;height:100%;padding:var(--space--large, 24px);--snk-personalized-filter--width:100%;--snk-personalized-filter--height:100%;--snk-personalized-filter--background-color-line:var(--color--disable-secondary);--snk-personalized-filter--margin-line:var(--border--radius-medium, 12px)}.snk-personalized-filter.sc-snk-personalized-filter{height:var(--snk-personalized-filter--width);width:var(--snk-personalized-filter--height)}.snk-personalized-filter__header-actions.sc-snk-personalized-filter{display:flex;gap:var(--space--medium)}.snk-personalized-filter__group.sc-snk-personalized-filter{flex:1}.snk-personalized-filter__expression-input--line.sc-snk-personalized-filter{width:100%;height:2px;background-color:var(--snk-personalized-filter--background-color-line);margin-top:var(--snk-personalized-filter--margin-line);margin-bottom:var(--snk-personalized-filter--margin-line)}.ez-box__main.sc-snk-personalized-filter{height:90%}.snk-personalized-filter__button-mode.sc-snk-personalized-filter{height:35px}";
@@ -4,16 +4,17 @@ Object.defineProperty(exports, '__esModule', { value: true });
4
4
 
5
5
  const index = require('./index-1894343a.js');
6
6
  const core = require('@sankhyalabs/core');
7
- const ISave = require('./ISave-2c455a77.js');
8
- require('./DataFetcher-0b6aa084.js');
7
+ const ISave = require('./ISave-e1e8ec96.js');
8
+ require('./DataFetcher-0c830777.js');
9
9
  require('./index-e3e39724.js');
10
10
  require('@sankhyalabs/ezui/dist/collection/utils/constants');
11
11
  require('@sankhyalabs/core/dist/dataunit/metadata/UnitMetadata');
12
- require('./dataunit-fetcher-8dffbcdf.js');
12
+ require('./dataunit-fetcher-86e286bb.js');
13
13
  require('./filter-item-type.enum-a7ffdaa6.js');
14
- require('./form-config-fetcher-5516d68a.js');
14
+ require('./form-config-fetcher-227b2db2.js');
15
15
  require('./constants-6d82e405.js');
16
16
  require('./PrintUtils-bcaeb82f.js');
17
+ require('./SnkMessageBuilder-32950342.js');
17
18
  require('@sankhyalabs/ezui/dist/collection/components/ez-grid/utils');
18
19
  require('@sankhyalabs/core/dist/utils/SortingUtils');
19
20
  require('./ResourceIDUtils-5ff86aa7.js');
@@ -7,20 +7,21 @@ const core = require('@sankhyalabs/core');
7
7
  const utils = require('@sankhyalabs/ezui/dist/collection/utils');
8
8
  const constants = require('./constants-6d82e405.js');
9
9
  const taskbarElements = require('./taskbar-elements-8a80420e.js');
10
- require('./DataFetcher-0b6aa084.js');
11
- require('./ISave-2c455a77.js');
12
- const SnkMultiSelectionListDataSource = require('./SnkMultiSelectionListDataSource-03b58f5a.js');
10
+ require('./DataFetcher-0c830777.js');
11
+ require('./ISave-e1e8ec96.js');
12
+ const SnkMultiSelectionListDataSource = require('./SnkMultiSelectionListDataSource-d30a96ef.js');
13
13
  const index$1 = require('./index-e3e39724.js');
14
14
  require('@sankhyalabs/ezui/dist/collection/utils/constants');
15
15
  require('@sankhyalabs/core/dist/dataunit/metadata/UnitMetadata');
16
- const dataunitFetcher = require('./dataunit-fetcher-8dffbcdf.js');
16
+ const dataunitFetcher = require('./dataunit-fetcher-86e286bb.js');
17
17
  require('./filter-item-type.enum-a7ffdaa6.js');
18
- const formConfigFetcher = require('./form-config-fetcher-5516d68a.js');
18
+ const formConfigFetcher = require('./form-config-fetcher-227b2db2.js');
19
19
  const taskbarProcessor = require('./taskbar-processor-2fba34a8.js');
20
- const ConfigStorage = require('./ConfigStorage-a4e1e518.js');
21
- const SnkFormConfigManager = require('./SnkFormConfigManager-b8c81493.js');
20
+ const ConfigStorage = require('./ConfigStorage-f61eedd2.js');
21
+ const SnkFormConfigManager = require('./SnkFormConfigManager-421f3581.js');
22
22
  const index$2 = require('./index-f0fe7e6e.js');
23
23
  require('./PrintUtils-bcaeb82f.js');
24
+ require('./SnkMessageBuilder-32950342.js');
24
25
  require('./GetSelectedRecordsIDsInfo-bd50caf1.js');
25
26
  require('./IFetchDataExporterParams-e78ec415.js');
26
27
  require('@sankhyalabs/ezui/dist/collection/components/ez-grid/utils/InMemoryFilterColumnDataSource');
@@ -47,6 +47,7 @@
47
47
  "./components/snk-grid/snk-grid.js",
48
48
  "./components/snk-grid-config/snk-grid-config.js",
49
49
  "./components/snk-grid-config/snk-select-box/snk-select-box.js",
50
+ "./components/snk-image-input/snk-image-input.js",
50
51
  "./components/snk-layout-form-config/snk-layout-form-config.js",
51
52
  "./components/snk-layout-form-config/snk-view-representation/snk-view-representation.js",
52
53
  "./components/snk-numbering-config/snk-numbering-config.js",
@@ -1557,7 +1557,7 @@ export class SnkApplication {
1557
1557
  "mutable": false,
1558
1558
  "complexType": {
1559
1559
  "original": "LoadByPkHandler",
1560
- "resolved": "(objPK: { pk: any; }, redirectFrom?: string) => void",
1560
+ "resolved": "(objPK: { pk: Record<string, any>; }, redirectFrom?: string) => void",
1561
1561
  "references": {
1562
1562
  "LoadByPkHandler": {
1563
1563
  "location": "global"
@@ -299,7 +299,7 @@ export class SnkDetailView {
299
299
  render() {
300
300
  this.updateLabel();
301
301
  //const cardConfig: IFormCardConfig = this._cardsState?.get(this.selectedForm);
302
- return (h(Host, null, h("snk-data-unit", { ref: (el) => this._snkDataUnit = el, dataUnitName: `${this.dataUnitName}`, onDataUnitReady: evt => this.dataUnitReadyHandler(evt), entityName: this.entityName, onDataStateChange: this.handleDataStateChange.bind(this), ignoreSaveMessage: this._currentView === VIEW_MODE.GRID, messagesBuilder: this.messagesBuilder, configName: this._configName }, h("ez-view-stack", { ref: (ref) => this.updateViewStack(ref) }, h("stack-item", null, h("div", { class: "ez-box ez-box--shadow grid-container" }, h("div", { class: "ez-title--primary ez-size-width--full ez-padding--large detail-header" }, h("div", { class: "ez-flex ez-text ez-text--bold ez-flex--justify-start ez-flex--align-items-center" }, this._levelPath ? h("span", { class: "level-path" }, this._levelPath + " /") : undefined, this.label)), h("snk-grid", { class: "ez-size-width--full", ref: (ref) => this._snkGrid = ref, configName: this._configName, messagesBuilder: this.messagesBuilder, onGridDoubleClick: () => this.emitSwitchEvent(VIEW_MODE.FORM), onActionClick: (evt) => this.executeActionHandler(evt), presentationMode: this.presentationMode, canEdit: this.canEdit, isDetail: true, taskbarCustomContainerId: this.taskbarCustomContainerId, gridHeaderCustomSlotId: "DETAIL_GRID_HEADER_CUSTOM_ELEMENTS", topTaskbarCustomSlotId: "DETAIL_GRID_TASKBAR_CUSTOM_ELEMENTS", outlineMode: false }))), h("stack-item", null, h("snk-form-view", { ref: (ref) => this._snkFormView = ref, canExpand: false, canFix: false, name: this.selectedForm, formMetadata: this._formMetadata, dataUnit: this.dataUnit, fields: this.getFormFields(), fieldToFocus: this._fieldToGetFocus, label: this.label, levelPath: this._levelPath, onFormItemsReady: ({ detail: formItems }) => this.formItemsReady.emit(formItems), onSnkRequestClearFieldToFocus: this.clearFieldToFocusHandler.bind(this), fieldSearch: this._fieldSearch }, h("snk-taskbar", { key: "guideViewerTaskbar", class: "form-taskbar", "data-element-id": "guideViewer", configName: this._configName, messagesBuilder: this.messagesBuilder, disabledButtons: this._disabledButtons, buttons: "INSERT,PREVIOUS,NEXT,DIVIDER,CLONE,REMOVE,MORE_OPTIONS,DIVIDER,GRID_MODE,CONFIGURATOR", primaryButton: "INSERT", presentationMode: this.presentationMode, onActionClick: evt => this.executeActionHandler(evt), dataUnit: this.dataUnit, resourceID: this.resourceID, customContainerId: this.taskbarCustomContainerId, customSlotId: "DETAIL_TASKBAR_CUSTOM_ELEMENTS", actionsSettingsList: this.getSettingsListForm() }, h("slot", { name: "DETAIL_TASKBAR_CUSTOM_ELEMENTS" })))), h("stack-item", null, h("snk-attach", { registerKey: this.attachmentRegisterKey, messagesBuilder: this.messagesBuilder, entityName: this.entityName, onBack: this.handleAttachBack.bind(this) }))))));
302
+ return (h(Host, null, h("snk-data-unit", { ref: (el) => this._snkDataUnit = el, dataUnitName: `${this.dataUnitName}`, onDataUnitReady: evt => this.dataUnitReadyHandler(evt), entityName: this.entityName, onDataStateChange: this.handleDataStateChange.bind(this), ignoreSaveMessage: this._currentView === VIEW_MODE.GRID, messagesBuilder: this.messagesBuilder, configName: this._configName }, h("ez-view-stack", { ref: (ref) => this.updateViewStack(ref) }, h("stack-item", null, h("div", { class: "ez-box ez-box--shadow grid-container" }, h("div", { class: "ez-title--primary ez-size-width--full ez-padding--large detail-header" }, h("div", { class: "ez-flex ez-text ez-text--bold ez-flex--justify-start ez-flex--align-items-center" }, this._levelPath ? h("span", { class: "level-path" }, this._levelPath + " /") : undefined, this.label)), h("snk-grid", { class: "ez-size-width--full", ref: (ref) => this._snkGrid = ref, configName: this._configName, messagesBuilder: this.messagesBuilder, onGridDoubleClick: () => this.emitSwitchEvent(VIEW_MODE.FORM), onActionClick: (evt) => this.executeActionHandler(evt), presentationMode: this.presentationMode, canEdit: this.canEdit, isDetail: true, taskbarCustomContainerId: this.taskbarCustomContainerId, gridHeaderCustomSlotId: "DETAIL_GRID_HEADER_CUSTOM_ELEMENTS", topTaskbarCustomSlotId: "DETAIL_GRID_TASKBAR_CUSTOM_ELEMENTS", outlineMode: false, enableGridInsert: true }))), h("stack-item", null, h("snk-form-view", { ref: (ref) => this._snkFormView = ref, canExpand: false, canFix: false, name: this.selectedForm, formMetadata: this._formMetadata, dataUnit: this.dataUnit, fields: this.getFormFields(), fieldToFocus: this._fieldToGetFocus, label: this.label, levelPath: this._levelPath, onFormItemsReady: ({ detail: formItems }) => this.formItemsReady.emit(formItems), onSnkRequestClearFieldToFocus: this.clearFieldToFocusHandler.bind(this), fieldSearch: this._fieldSearch, entityPath: this.entityName }, h("snk-taskbar", { key: "guideViewerTaskbar", class: "form-taskbar", "data-element-id": "guideViewer", configName: this._configName, messagesBuilder: this.messagesBuilder, disabledButtons: this._disabledButtons, buttons: "INSERT,PREVIOUS,NEXT,DIVIDER,CLONE,REMOVE,MORE_OPTIONS,DIVIDER,GRID_MODE,CONFIGURATOR", primaryButton: "INSERT", presentationMode: this.presentationMode, onActionClick: evt => this.executeActionHandler(evt), dataUnit: this.dataUnit, resourceID: this.resourceID, customContainerId: this.taskbarCustomContainerId, customSlotId: "DETAIL_TASKBAR_CUSTOM_ELEMENTS", actionsSettingsList: this.getSettingsListForm() }, h("slot", { name: "DETAIL_TASKBAR_CUSTOM_ELEMENTS" })))), h("stack-item", null, h("snk-attach", { registerKey: this.attachmentRegisterKey, messagesBuilder: this.messagesBuilder, entityName: this.entityName, onBack: this.handleAttachBack.bind(this) }))))));
303
303
  }
304
304
  static get is() { return "snk-detail-view"; }
305
305
  static get encapsulation() { return "scoped"; }
@@ -1,11 +1,39 @@
1
- import { ApplicationContext, ElementIDUtils } from "@sankhyalabs/core";
1
+ var __rest = (this && this.__rest) || function (s, e) {
2
+ var t = {};
3
+ for (var p in s)
4
+ if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
5
+ t[p] = s[p];
6
+ if (s != null && typeof Object.getOwnPropertySymbols === "function")
7
+ for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
8
+ if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))
9
+ t[p[i]] = s[p[i]];
10
+ }
11
+ return t;
12
+ };
13
+ import { Action, ApplicationContext, ElementIDUtils, UserInterface } from "@sankhyalabs/core";
2
14
  import { Host, h } from "@stencil/core";
3
15
  import { DataBinder } from "@sankhyalabs/ezui/dist/collection/utils/form";
4
16
  import { focusOnFieldSerch, SEARCH_FIELD_FULL_WIDTH, FormLayout } from '@sankhyalabs/ezui/dist/collection/utils';
17
+ import { getPKs } from "../../snk-image-input/utils/ImageUtils";
5
18
  export class SnkFormView {
6
19
  constructor() {
7
20
  this._customEditors = new Map();
8
21
  this._fieldProps = new Map();
22
+ this.dataUnitObserver = async (action) => {
23
+ if (action.type === Action.RECORDS_COPIED) {
24
+ const sourcePK = this.buildSourceRecordPK(action);
25
+ this.getImageField().forEach(async (field) => {
26
+ this.dataUnit.setFieldValue(field.name, JSON.stringify(sourcePK));
27
+ });
28
+ }
29
+ };
30
+ this.customUiBuilders = new Map([
31
+ [UserInterface.IMAGE, (_a) => {
32
+ var { name } = _a, props = __rest(_a, ["name"]);
33
+ return h("snk-image-input", Object.assign({ dataUnit: this.dataUnit, maxSize: Infinity, fieldName: name, entityName: this.entityPath }, props));
34
+ }
35
+ ]
36
+ ]);
9
37
  this._singleColumn = false;
10
38
  this.levelPath = undefined;
11
39
  this.fieldSearch = undefined;
@@ -23,6 +51,7 @@ export class SnkFormView {
23
51
  this.fieldToFocus = undefined;
24
52
  this.customEditors = undefined;
25
53
  this.fieldsProps = undefined;
54
+ this.entityPath = undefined;
26
55
  }
27
56
  async showUp() {
28
57
  if (this._formView) {
@@ -72,6 +101,11 @@ export class SnkFormView {
72
101
  }
73
102
  }
74
103
  }
104
+ async observeDataUnit(newValue, oldValue) {
105
+ if (newValue !== oldValue && newValue) {
106
+ newValue.subscribe(this.dataUnitObserver);
107
+ }
108
+ }
75
109
  changeFix() {
76
110
  this.fixed = !this.fixed;
77
111
  this.emitEvent("fixed");
@@ -129,6 +163,9 @@ export class SnkFormView {
129
163
  if (this._dataBinder != undefined) {
130
164
  this._dataBinder.onDisconnectedCallback();
131
165
  }
166
+ if (this.dataUnit) {
167
+ this.dataUnit.unsubscribe(this.dataUnitObserver);
168
+ }
132
169
  }
133
170
  componentDidLoad() {
134
171
  this.observePropsCustomEditor(this.customEditors);
@@ -187,6 +224,22 @@ export class SnkFormView {
187
224
  });
188
225
  }
189
226
  }
227
+ buildSourceRecordPK(action) {
228
+ var _a, _b;
229
+ const currentRecord = ((_a = action.payload) === null || _a === void 0 ? void 0 : _a[0]) || {};
230
+ const sourceBase64 = currentRecord["__record__source__id__"];
231
+ const sourceRecord = JSON.parse(atob(sourceBase64 || ''));
232
+ delete sourceRecord["__DATA_UNIT_NAME__"];
233
+ const pkFields = Object.keys(getPKs(this.dataUnit));
234
+ const filteredSourceRecord = {};
235
+ for (const pkField of pkFields) {
236
+ filteredSourceRecord[pkField] = (_b = sourceRecord[pkField]) === null || _b === void 0 ? void 0 : _b.value;
237
+ }
238
+ return filteredSourceRecord;
239
+ }
240
+ getImageField() {
241
+ return this.dataUnit.metadata.fields.filter(field => field.userInterface === UserInterface.IMAGE);
242
+ }
190
243
  render() {
191
244
  return (h(Host, { class: "ez-box__container" }, h("div", { class: "summary-header ez-flex ez-size-width--full", ref: ref => this._headerContainer = ref }, h("div", { class: "ez-flex ez-text ez-title--primary ez-text--bold ez-flex--justify-start ez-flex--align-items-center ez-col--sd-9" }, this.levelPath ? h("span", { class: "level-path" }, this.levelPath + " /") : undefined, this.label), h("div", { class: "ez-flex ez-flex--justify-end ez-col--sd-3" }, this.canFix &&
192
245
  h("ez-button", { class: "ez-padding-left--medium", mode: "icon", size: "small", iconName: this.fixed ? "un-pin" : "push-pin", "data-element-id": ElementIDUtils.getInternalIDInfo("toggleFixed_ezFormCard"), onClick: () => this.changeFix(), title: this.fixed ? "Desafixar" : "Fixar" }), this.canExpand &&
@@ -194,7 +247,7 @@ export class SnkFormView {
194
247
  ?
195
248
  h("snk-form-summary", { summary: this.getCardSummary() })
196
249
  :
197
- h("ez-form-view", { ref: ref => this._formView = ref, fields: this.fields, onEzContentReady: evt => this.bindFields(evt.detail), onFormItemsReady: (event) => this.handleFormItemsReady(event), singleColumn: this._singleColumn }), this.fieldSearch && h("ez-popover", { ref: elem => (this._ezPopoverFieldColumn = elem), overlayType: "none" }, this.fieldSearch)));
250
+ h("ez-form-view", { ref: ref => this._formView = ref, fields: this.fields, onEzContentReady: evt => this.bindFields(evt.detail), onFormItemsReady: (event) => this.handleFormItemsReady(event), singleColumn: this._singleColumn, customUiBuilders: this.customUiBuilders }), this.fieldSearch && h("ez-popover", { ref: elem => (this._ezPopoverFieldColumn = elem), overlayType: "none" }, this.fieldSearch)));
198
251
  }
199
252
  static get is() { return "snk-form-view"; }
200
253
  static get encapsulation() { return "scoped"; }
@@ -510,6 +563,23 @@ export class SnkFormView {
510
563
  "tags": [],
511
564
  "text": "Lista de propriedades que ser\u00E3o alteradas/adicionadas por coluna."
512
565
  }
566
+ },
567
+ "entityPath": {
568
+ "type": "string",
569
+ "mutable": false,
570
+ "complexType": {
571
+ "original": "string",
572
+ "resolved": "string",
573
+ "references": {}
574
+ },
575
+ "required": false,
576
+ "optional": false,
577
+ "docs": {
578
+ "tags": [],
579
+ "text": "Determina todo o caminho de entidades."
580
+ },
581
+ "attribute": "entity-path",
582
+ "reflect": false
513
583
  }
514
584
  };
515
585
  }
@@ -675,6 +745,9 @@ export class SnkFormView {
675
745
  }, {
676
746
  "propName": "fieldsProps",
677
747
  "methodName": "observeFieldsProps"
748
+ }, {
749
+ "propName": "dataUnit",
750
+ "methodName": "observeDataUnit"
678
751
  }];
679
752
  }
680
753
  }
@@ -283,7 +283,7 @@ export class SnkGuidesViewer {
283
283
  if (sheet == undefined) {
284
284
  return;
285
285
  }
286
- return h("snk-form-view", { levelPath: params.levelPath, label: sheet.label, name: formName, fields: sheet.fields, formMetadata: params.formMetadata, dataUnit: params.dataUnit, recordsValidator: params.recordsValidator, contracted: (cardConfig === null || cardConfig === void 0 ? void 0 : cardConfig.presentation) === "CONTRACTED", fixed: cardConfig === null || cardConfig === void 0 ? void 0 : cardConfig.fixed, summaryFields: (_b = (_a = params.formConfig) === null || _a === void 0 ? void 0 : _a.summary) === null || _b === void 0 ? void 0 : _b.get(formName), fieldToFocus: params.fieldToFocus, key: formName, onSnkRequestClearFieldToFocus: _ => { var _a; return (_a = params.onRequestClearFieldToFocus) === null || _a === void 0 ? void 0 : _a.call(params); }, customEditors: params.propsCustomEditor, fieldsProps: params.fieldsProps });
286
+ return h("snk-form-view", { levelPath: params.levelPath, label: sheet.label, name: formName, fields: sheet.fields, formMetadata: params.formMetadata, dataUnit: params.dataUnit, recordsValidator: params.recordsValidator, contracted: (cardConfig === null || cardConfig === void 0 ? void 0 : cardConfig.presentation) === "CONTRACTED", fixed: cardConfig === null || cardConfig === void 0 ? void 0 : cardConfig.fixed, summaryFields: (_b = (_a = params.formConfig) === null || _a === void 0 ? void 0 : _a.summary) === null || _b === void 0 ? void 0 : _b.get(formName), fieldToFocus: params.fieldToFocus, key: formName, onSnkRequestClearFieldToFocus: _ => { var _a; return (_a = params.onRequestClearFieldToFocus) === null || _a === void 0 ? void 0 : _a.call(params); }, customEditors: params.propsCustomEditor, fieldsProps: params.fieldsProps, entityPath: params.entityPath });
287
287
  })));
288
288
  }
289
289
  wrapDetail(levels, content) {
@@ -328,7 +328,7 @@ export class SnkGuidesViewer {
328
328
  if (!sheet)
329
329
  return;
330
330
  const cardConfig = (_b = (_a = this.masterFormConfig) === null || _a === void 0 ? void 0 : _a.cardsState) === null || _b === void 0 ? void 0 : _b.get(cardId);
331
- return (h("snk-form-view", { ref: ref => this._mainForm = ref, fixed: cardConfig === null || cardConfig === void 0 ? void 0 : cardConfig.fixed, summaryFields: (_d = (_c = this.masterFormConfig) === null || _c === void 0 ? void 0 : _c.summary) === null || _d === void 0 ? void 0 : _d.get(cardId), name: cardId, label: sheet.label, fields: sheet.fields, dataUnit: this.dataUnit, formMetadata: this._masterFormMetadata, recordsValidator: this.recordsValidator, fieldToFocus: this._fieldToGetFocus, key: cardId, onSnkRequestClearFieldToFocus: _ => this.clearFieldToFocusHandler(), customEditors: this._customEditors, fieldsProps: this._fieldsProps, fieldSearch: this._fieldSearch }, this.presentationMode == PresentationMode.SECONDARY && this.buildTaskBar()));
331
+ return (h("snk-form-view", { ref: ref => this._mainForm = ref, fixed: cardConfig === null || cardConfig === void 0 ? void 0 : cardConfig.fixed, summaryFields: (_d = (_c = this.masterFormConfig) === null || _c === void 0 ? void 0 : _c.summary) === null || _d === void 0 ? void 0 : _d.get(cardId), name: cardId, label: sheet.label, fields: sheet.fields, dataUnit: this.dataUnit, formMetadata: this._masterFormMetadata, recordsValidator: this.recordsValidator, fieldToFocus: this._fieldToGetFocus, key: cardId, onSnkRequestClearFieldToFocus: _ => this.clearFieldToFocusHandler(), customEditors: this._customEditors, fieldsProps: this._fieldsProps, fieldSearch: this._fieldSearch, entityPath: this.entityPath }, this.presentationMode == PresentationMode.SECONDARY && this.buildTaskBar()));
332
332
  }
333
333
  isDetailGuide(childEntityName, levels) {
334
334
  return childEntityName || levels.length > 0;
@@ -600,7 +600,8 @@ export class SnkGuidesViewer {
600
600
  fieldToFocus: this._fieldToGetFocus,
601
601
  onRequestClearFieldToFocus: this.clearFieldToFocusHandler.bind(this),
602
602
  propsCustomEditor: this._customEditors,
603
- fieldsProps: this._fieldsProps
603
+ fieldsProps: this._fieldsProps,
604
+ entityPath: this.entityPath
604
605
  }), this.getContent())), h("snk-configurator", { ref: (ref) => this._snkConfigurator = ref, viewMode: this.getConfigViewMode(), onConfigSelected: (evt) => this.changeConfigViewMode(evt.detail), messagesBuilder: this.messagesBuilder, onOpenConfig: (evt) => this.openConfig(evt.detail), resourceID: this.resourceID })));
605
606
  }
606
607
  render() {
@@ -0,0 +1,3 @@
1
+ :host {
2
+ display: block;
3
+ }
@@ -0,0 +1,326 @@
1
+ import { ApplicationContext } from '@sankhyalabs/core';
2
+ import { h, Host } from '@stencil/core';
3
+ import { SnkMessageBuilder } from '../../lib/message/SnkMessageBuilder';
4
+ import { base64ToBlob, buildFileKey, downloadImage, getPKs, sessionFileUpload } from './utils/ImageUtils';
5
+ import { Action } from '@sankhyalabs/core';
6
+ export class SnkImageInput {
7
+ constructor() {
8
+ this.dataUnitObserver = async (action) => {
9
+ var _a;
10
+ const actionsMoveSelection = [Action.NEXT_SELECTED, Action.PREVIOUS_SELECTED];
11
+ if (actionsMoveSelection.includes(action.type)) {
12
+ await this.loadImage();
13
+ return;
14
+ }
15
+ const selection = ((_a = action.payload) === null || _a === void 0 ? void 0 : _a.selection) || [];
16
+ if (action.type === Action.SELECTION_CHANGED && selection.length > 0) {
17
+ await this.loadImage();
18
+ return;
19
+ }
20
+ if (action.type === Action.RECORDS_ADDED) {
21
+ await this.clearImage();
22
+ return;
23
+ }
24
+ };
25
+ this.dataUnit = undefined;
26
+ this.fieldName = undefined;
27
+ this.entityName = undefined;
28
+ this.enabled = true;
29
+ this.acceptType = undefined;
30
+ this.maxSize = undefined;
31
+ this.label = undefined;
32
+ this.imageValue = undefined;
33
+ this.loading = true;
34
+ }
35
+ /**
36
+ * Força o reload da imagem
37
+ */
38
+ async reloadImage(pks) {
39
+ await this.loadImage(pks);
40
+ }
41
+ getMessage(key, params) {
42
+ if (!this.messagesBuilder) {
43
+ this.messagesBuilder = new SnkMessageBuilder();
44
+ }
45
+ return this.messagesBuilder.getMessage(key, params);
46
+ }
47
+ async clearImage() {
48
+ this.imageValue = undefined;
49
+ }
50
+ async handleImageChange(event) {
51
+ const base64 = event.detail;
52
+ if (!base64) {
53
+ await this.clearImage();
54
+ await this.updatedataUnitField(true);
55
+ return;
56
+ }
57
+ const blob = await base64ToBlob(base64);
58
+ if (this.maxSize && blob.size > this.maxSize * 1024) {
59
+ const errorMsg = this.getMessage('snkImageInput.errorImageSize') + this.maxSize + '(KB)';
60
+ this.imageError.emit(errorMsg);
61
+ if (this.application) {
62
+ await this.application.error(this.getMessage('snkImageInput.errorTitle'), errorMsg);
63
+ }
64
+ return;
65
+ }
66
+ this.imageValue = base64;
67
+ await sessionFileUpload(blob, this.entityName, this.fieldName);
68
+ await this.updatedataUnitField();
69
+ }
70
+ async updatedataUnitField(deleted = false) {
71
+ if (!this.dataUnit || !this.dataUnit.getSelectedRecord()) {
72
+ return;
73
+ }
74
+ if (deleted) {
75
+ await this.dataUnit.setFieldValue(this.fieldName, 'deletado');
76
+ }
77
+ else {
78
+ await this.dataUnit.setFieldValue(this.fieldName, `$file.session.key{${buildFileKey(this.entityName, this.fieldName)}}`);
79
+ }
80
+ }
81
+ async handleImageError(event) {
82
+ this.imageError.emit(event.detail);
83
+ if (this.application) {
84
+ await this.application.error(this.getMessage('snkImageInput.errorTitle'), event.detail);
85
+ }
86
+ }
87
+ getPksFromDataUnit() {
88
+ if (!this.dataUnit) {
89
+ return undefined;
90
+ }
91
+ const selectedRecord = this.dataUnit.getSelectedRecord();
92
+ if (!selectedRecord) {
93
+ return undefined;
94
+ }
95
+ const fieldValue = selectedRecord[this.fieldName];
96
+ if (!fieldValue) {
97
+ return undefined;
98
+ }
99
+ try {
100
+ const pk = JSON.parse(fieldValue);
101
+ return pk;
102
+ }
103
+ catch (error) {
104
+ console.error('Error parsing PK from data unit field:', error);
105
+ return undefined;
106
+ }
107
+ }
108
+ async loadImage(pks) {
109
+ var _a;
110
+ this.loading = true;
111
+ if (this.dataUnit && this.entityName) {
112
+ pks = (_a = pks !== null && pks !== void 0 ? pks : this.getPksFromDataUnit()) !== null && _a !== void 0 ? _a : getPKs(this.dataUnit);
113
+ this.imageValue = await downloadImage(pks, this.fieldName, this.entityName);
114
+ }
115
+ this.loading = false;
116
+ }
117
+ async componentWillLoad() {
118
+ this.application = ApplicationContext.getContextValue("__SNK__APPLICATION__");
119
+ if (!this.messagesBuilder) {
120
+ this.messagesBuilder = new SnkMessageBuilder();
121
+ }
122
+ if (this.dataUnit) {
123
+ this.dataUnit.subscribe(this.dataUnitObserver);
124
+ }
125
+ }
126
+ disconnectedCallback() {
127
+ if (this.dataUnit) {
128
+ this.dataUnit.unsubscribe(this.dataUnitObserver);
129
+ }
130
+ }
131
+ async componentDidLoad() {
132
+ await this.loadImage();
133
+ }
134
+ render() {
135
+ return (h(Host, null, h("ez-image-input", { enabled: this.enabled, label: this.label, name: this.fieldName, value: this.imageValue, maxFileSize: this.maxSize ? this.maxSize * 1024 : undefined, accept: this.acceptType || 'image/png,image/jpeg,image/gif', onEzChange: (e) => this.handleImageChange(e), onEzError: (e) => this.handleImageError(e), loading: this.loading })));
136
+ }
137
+ static get is() { return "snk-image-input"; }
138
+ static get encapsulation() { return "shadow"; }
139
+ static get originalStyleUrls() {
140
+ return {
141
+ "$": ["snk-image-input.css"]
142
+ };
143
+ }
144
+ static get styleUrls() {
145
+ return {
146
+ "$": ["snk-image-input.css"]
147
+ };
148
+ }
149
+ static get properties() {
150
+ return {
151
+ "dataUnit": {
152
+ "type": "unknown",
153
+ "mutable": false,
154
+ "complexType": {
155
+ "original": "DataUnit",
156
+ "resolved": "DataUnit",
157
+ "references": {
158
+ "DataUnit": {
159
+ "location": "import",
160
+ "path": "@sankhyalabs/core"
161
+ }
162
+ }
163
+ },
164
+ "required": false,
165
+ "optional": true,
166
+ "docs": {
167
+ "tags": [],
168
+ "text": "DataUnit associado ao componente"
169
+ }
170
+ },
171
+ "fieldName": {
172
+ "type": "string",
173
+ "mutable": false,
174
+ "complexType": {
175
+ "original": "string",
176
+ "resolved": "string",
177
+ "references": {}
178
+ },
179
+ "required": false,
180
+ "optional": false,
181
+ "docs": {
182
+ "tags": [],
183
+ "text": "Nome do campo no DataUnit"
184
+ },
185
+ "attribute": "field-name",
186
+ "reflect": false
187
+ },
188
+ "entityName": {
189
+ "type": "string",
190
+ "mutable": false,
191
+ "complexType": {
192
+ "original": "string",
193
+ "resolved": "string",
194
+ "references": {}
195
+ },
196
+ "required": false,
197
+ "optional": true,
198
+ "docs": {
199
+ "tags": [],
200
+ "text": "Nome da entidade (usado quando n\u00E3o h\u00E1 DataUnit)"
201
+ },
202
+ "attribute": "entity-name",
203
+ "reflect": false
204
+ },
205
+ "enabled": {
206
+ "type": "boolean",
207
+ "mutable": false,
208
+ "complexType": {
209
+ "original": "boolean",
210
+ "resolved": "boolean",
211
+ "references": {}
212
+ },
213
+ "required": false,
214
+ "optional": false,
215
+ "docs": {
216
+ "tags": [],
217
+ "text": "Define se est\u00E1 habilitado"
218
+ },
219
+ "attribute": "enabled",
220
+ "reflect": false,
221
+ "defaultValue": "true"
222
+ },
223
+ "acceptType": {
224
+ "type": "string",
225
+ "mutable": false,
226
+ "complexType": {
227
+ "original": "string",
228
+ "resolved": "string",
229
+ "references": {}
230
+ },
231
+ "required": false,
232
+ "optional": true,
233
+ "docs": {
234
+ "tags": [],
235
+ "text": "Tipos MIME aceitos (separados por v\u00EDrgula)"
236
+ },
237
+ "attribute": "accept-type",
238
+ "reflect": false
239
+ },
240
+ "maxSize": {
241
+ "type": "number",
242
+ "mutable": false,
243
+ "complexType": {
244
+ "original": "number",
245
+ "resolved": "number",
246
+ "references": {}
247
+ },
248
+ "required": false,
249
+ "optional": true,
250
+ "docs": {
251
+ "tags": [],
252
+ "text": "Tamanho m\u00E1ximo do arquivo em KB"
253
+ },
254
+ "attribute": "max-size",
255
+ "reflect": false
256
+ },
257
+ "label": {
258
+ "type": "string",
259
+ "mutable": false,
260
+ "complexType": {
261
+ "original": "string",
262
+ "resolved": "string",
263
+ "references": {}
264
+ },
265
+ "required": false,
266
+ "optional": true,
267
+ "docs": {
268
+ "tags": [],
269
+ "text": "Label do componente"
270
+ },
271
+ "attribute": "label",
272
+ "reflect": false
273
+ }
274
+ };
275
+ }
276
+ static get states() {
277
+ return {
278
+ "imageValue": {},
279
+ "loading": {}
280
+ };
281
+ }
282
+ static get events() {
283
+ return [{
284
+ "method": "imageError",
285
+ "name": "imageError",
286
+ "bubbles": true,
287
+ "cancelable": true,
288
+ "composed": true,
289
+ "docs": {
290
+ "tags": [],
291
+ "text": "Evento disparado quando h\u00E1 erro"
292
+ },
293
+ "complexType": {
294
+ "original": "string",
295
+ "resolved": "string",
296
+ "references": {}
297
+ }
298
+ }];
299
+ }
300
+ static get methods() {
301
+ return {
302
+ "reloadImage": {
303
+ "complexType": {
304
+ "signature": "(pks?: Record<string, any>) => Promise<void>",
305
+ "parameters": [{
306
+ "tags": [],
307
+ "text": ""
308
+ }],
309
+ "references": {
310
+ "Promise": {
311
+ "location": "global"
312
+ },
313
+ "Record": {
314
+ "location": "global"
315
+ }
316
+ },
317
+ "return": "Promise<void>"
318
+ },
319
+ "docs": {
320
+ "text": "For\u00E7a o reload da imagem",
321
+ "tags": []
322
+ }
323
+ }
324
+ };
325
+ }
326
+ }