@sankhyalabs/sankhyablocks 10.1.0-dev.4 → 10.1.0-dev.5

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 (139) hide show
  1. package/dist/cjs/{ConfigStorage-b29e31be.js → ConfigStorage-72f34bd4.js} +2 -2
  2. package/dist/cjs/{DataFetcher-ed9d97ea.js → DataFetcher-991b0349.js} +19 -1
  3. package/dist/cjs/{FormConfigHelper-ebb77625.js → FormConfigHelper-e253a418.js} +42 -0
  4. package/dist/cjs/{ISave-81eb2fbc.js → ISave-ebf6b4ed.js} +1 -1
  5. package/dist/cjs/{SnkFormConfigManager-6838389c.js → SnkFormConfigManager-cdbb29d4.js} +4 -4
  6. package/dist/cjs/{SnkMultiSelectionListDataSource-1e804147.js → SnkMultiSelectionListDataSource-011bec79.js} +4 -4
  7. package/dist/cjs/{auth-fetcher-cc28d847.js → auth-fetcher-c3cac878.js} +1 -1
  8. package/dist/cjs/{dataunit-fetcher-ab1cc071.js → dataunit-fetcher-8bf469e7.js} +1 -1
  9. package/dist/cjs/field-config_2.cjs.entry.js +1 -1
  10. package/dist/cjs/fields-layout.cjs.entry.js +4 -1
  11. package/dist/cjs/fields-selector.cjs.entry.js +1 -1
  12. package/dist/cjs/{form-config-fetcher-f0897eb5.js → form-config-fetcher-c7af90d8.js} +1 -1
  13. package/dist/cjs/guides-configurator.cjs.entry.js +3 -1
  14. package/dist/cjs/loader.cjs.js +1 -1
  15. package/dist/cjs/pesquisa-grid_2.cjs.entry.js +4 -4
  16. package/dist/cjs/sankhyablocks.cjs.js +1 -1
  17. package/dist/cjs/snk-actions-button_9.cjs.entry.js +5 -5
  18. package/dist/cjs/snk-application.cjs.entry.js +6 -6
  19. package/dist/cjs/snk-attach.cjs.entry.js +5 -5
  20. package/dist/cjs/snk-crud.cjs.entry.js +9 -7
  21. package/dist/cjs/snk-data-exporter.cjs.entry.js +5 -5
  22. package/dist/cjs/{snk-data-unit-68992932.js → snk-data-unit-7d587ad5.js} +2 -2
  23. package/dist/cjs/snk-data-unit.cjs.entry.js +3 -3
  24. package/dist/cjs/snk-detail-view.cjs.entry.js +7 -7
  25. package/dist/cjs/snk-filter-bar_4.cjs.entry.js +3 -3
  26. package/dist/cjs/snk-filter-modal-item.cjs.entry.js +3 -3
  27. package/dist/cjs/snk-form_2.cjs.entry.js +22 -9
  28. package/dist/cjs/snk-grid.cjs.entry.js +6 -6
  29. package/dist/cjs/{snk-guides-viewer-8b841753.js → snk-guides-viewer-366d5c32.js} +90 -28
  30. package/dist/cjs/snk-guides-viewer.cjs.entry.js +7 -7
  31. package/dist/cjs/snk-personalized-filter.cjs.entry.js +3 -3
  32. package/dist/cjs/snk-pesquisa.cjs.entry.js +4 -4
  33. package/dist/cjs/snk-simple-crud.cjs.entry.js +7 -7
  34. package/dist/cjs/snk-taskbar.cjs.entry.js +56 -44
  35. package/dist/collection/collection-manifest.json +1 -1
  36. package/dist/collection/components/snk-crud/snk-crud.js +29 -2
  37. package/dist/collection/components/snk-crud/subcomponents/snk-guides-viewer.js +124 -23
  38. package/dist/collection/components/snk-form-config/FormConfigHelper.js +40 -0
  39. package/dist/collection/components/snk-form-config/SnkFormConfigManager.js +3 -3
  40. package/dist/collection/components/snk-form-config/fields-layout/fields-layout.js +3 -0
  41. package/dist/collection/components/snk-form-config/guides-configurator/guides-configurator.js +3 -1
  42. package/dist/collection/components/snk-form-config/snk-form-config.js +43 -6
  43. package/dist/collection/components/snk-taskbar/snk-taskbar.js +58 -44
  44. package/dist/collection/lib/message/resources/en-us/snk-form.msg.js +6 -0
  45. package/dist/collection/lib/message/resources/es-es/snk-form.msg.js +6 -0
  46. package/dist/collection/lib/message/resources/pt-br/snk-form.msg.js +7 -1
  47. package/dist/components/DataFetcher.js +19 -1
  48. package/dist/components/SnkFormConfigManager.js +3 -3
  49. package/dist/components/field-config2.js +41 -1
  50. package/dist/components/fields-layout2.js +3 -0
  51. package/dist/components/guides-configurator2.js +3 -1
  52. package/dist/components/snk-crud.js +6 -2
  53. package/dist/components/snk-detail-view2.js +86 -23
  54. package/dist/components/snk-form-config2.js +19 -5
  55. package/dist/components/snk-taskbar2.js +57 -45
  56. package/dist/esm/{ConfigStorage-13d80e36.js → ConfigStorage-22324b6b.js} +2 -2
  57. package/dist/esm/{DataFetcher-f4ccd9f3.js → DataFetcher-450828a0.js} +19 -1
  58. package/dist/esm/{FormConfigHelper-4e42f0b6.js → FormConfigHelper-e89ca25c.js} +41 -1
  59. package/dist/esm/{ISave-288fa9df.js → ISave-61153166.js} +1 -1
  60. package/dist/esm/{SnkFormConfigManager-3ee2937b.js → SnkFormConfigManager-b5a92e12.js} +4 -4
  61. package/dist/esm/{SnkMultiSelectionListDataSource-5d3a93f2.js → SnkMultiSelectionListDataSource-d7ce2e54.js} +4 -4
  62. package/dist/esm/{auth-fetcher-59ab0c67.js → auth-fetcher-eef9d01e.js} +1 -1
  63. package/dist/esm/{dataunit-fetcher-c4f9f222.js → dataunit-fetcher-da9596f6.js} +1 -1
  64. package/dist/esm/field-config_2.entry.js +1 -1
  65. package/dist/esm/fields-layout.entry.js +4 -1
  66. package/dist/esm/fields-selector.entry.js +1 -1
  67. package/dist/esm/{form-config-fetcher-6a00fe9e.js → form-config-fetcher-8d0a5e1c.js} +1 -1
  68. package/dist/esm/guides-configurator.entry.js +3 -1
  69. package/dist/esm/loader.js +1 -1
  70. package/dist/esm/pesquisa-grid_2.entry.js +4 -4
  71. package/dist/esm/sankhyablocks.js +1 -1
  72. package/dist/esm/snk-actions-button_9.entry.js +5 -5
  73. package/dist/esm/snk-application.entry.js +6 -6
  74. package/dist/esm/snk-attach.entry.js +5 -5
  75. package/dist/esm/snk-crud.entry.js +9 -7
  76. package/dist/esm/snk-data-exporter.entry.js +5 -5
  77. package/dist/esm/{snk-data-unit-0edeb967.js → snk-data-unit-99616a07.js} +2 -2
  78. package/dist/esm/snk-data-unit.entry.js +3 -3
  79. package/dist/esm/snk-detail-view.entry.js +7 -7
  80. package/dist/esm/snk-filter-bar_4.entry.js +3 -3
  81. package/dist/esm/snk-filter-modal-item.entry.js +3 -3
  82. package/dist/esm/snk-form_2.entry.js +22 -9
  83. package/dist/esm/snk-grid.entry.js +6 -6
  84. package/dist/esm/{snk-guides-viewer-9cd4d20f.js → snk-guides-viewer-240de636.js} +90 -28
  85. package/dist/esm/snk-guides-viewer.entry.js +7 -7
  86. package/dist/esm/snk-personalized-filter.entry.js +3 -3
  87. package/dist/esm/snk-pesquisa.entry.js +4 -4
  88. package/dist/esm/snk-simple-crud.entry.js +7 -7
  89. package/dist/esm/snk-taskbar.entry.js +57 -45
  90. package/dist/sankhyablocks/{p-1c2971e4.js → p-002d4d2b.js} +1 -1
  91. package/dist/sankhyablocks/{p-ae108ffd.entry.js → p-0948dc0a.entry.js} +1 -1
  92. package/dist/sankhyablocks/{p-7b3ca294.entry.js → p-0b9a42ad.entry.js} +1 -1
  93. package/dist/sankhyablocks/p-118c221e.js +1 -0
  94. package/dist/sankhyablocks/{p-dc851b6e.entry.js → p-1a9c5684.entry.js} +1 -1
  95. package/dist/sankhyablocks/p-1d589380.entry.js +1 -0
  96. package/dist/sankhyablocks/{p-d9c54991.js → p-28f50632.js} +1 -1
  97. package/dist/sankhyablocks/p-39be771c.js +1 -0
  98. package/dist/sankhyablocks/{p-26e0f63c.entry.js → p-4963dd2a.entry.js} +1 -1
  99. package/dist/sankhyablocks/p-55f6fef2.entry.js +1 -0
  100. package/dist/sankhyablocks/p-56f16390.entry.js +1 -0
  101. package/dist/sankhyablocks/{p-5304753a.js → p-58683e28.js} +2 -2
  102. package/dist/sankhyablocks/{p-11346b8d.entry.js → p-5ea893c5.entry.js} +1 -1
  103. package/dist/sankhyablocks/{p-f15478a1.js → p-62aef37a.js} +1 -1
  104. package/dist/sankhyablocks/{p-34f447ba.entry.js → p-62e9b9b8.entry.js} +1 -1
  105. package/dist/sankhyablocks/{p-e9021f79.entry.js → p-669bb869.entry.js} +1 -1
  106. package/dist/sankhyablocks/{p-6180de07.entry.js → p-6ee2ca7a.entry.js} +1 -1
  107. package/dist/sankhyablocks/p-7cac3870.entry.js +1 -0
  108. package/dist/sankhyablocks/{p-78ff8734.js → p-7d6f1285.js} +1 -1
  109. package/dist/sankhyablocks/{p-53599b26.js → p-840fb68c.js} +1 -1
  110. package/dist/sankhyablocks/{p-b4322b87.entry.js → p-86e54841.entry.js} +1 -1
  111. package/dist/sankhyablocks/{p-34df7eca.entry.js → p-88b337fe.entry.js} +1 -1
  112. package/dist/sankhyablocks/{p-3d021bef.entry.js → p-91005a00.entry.js} +1 -1
  113. package/dist/sankhyablocks/p-92cfc028.js +1 -0
  114. package/dist/sankhyablocks/{p-44939a0e.entry.js → p-ada013c0.entry.js} +1 -1
  115. package/dist/sankhyablocks/{p-9317942f.js → p-c35fc941.js} +1 -1
  116. package/dist/sankhyablocks/p-c98c79c3.entry.js +1 -0
  117. package/dist/sankhyablocks/{p-1858c023.entry.js → p-cadf4846.entry.js} +1 -1
  118. package/dist/sankhyablocks/{p-38e56b68.entry.js → p-e91c3c57.entry.js} +1 -1
  119. package/dist/sankhyablocks/{p-f8f29e1a.entry.js → p-ea729922.entry.js} +1 -1
  120. package/dist/sankhyablocks/p-ec5fbad8.js +1 -0
  121. package/dist/sankhyablocks/{p-80014119.entry.js → p-f5e942b7.entry.js} +1 -1
  122. package/dist/sankhyablocks/sankhyablocks.esm.js +1 -1
  123. package/dist/types/components/snk-crud/snk-crud.d.ts +6 -0
  124. package/dist/types/components/snk-crud/subcomponents/snk-guides-viewer.d.ts +22 -0
  125. package/dist/types/components/snk-form-config/FormConfigHelper.d.ts +5 -0
  126. package/dist/types/components/snk-form-config/SnkFormConfigManager.d.ts +1 -1
  127. package/dist/types/components/snk-form-config/snk-form-config.d.ts +8 -2
  128. package/dist/types/components/snk-taskbar/snk-taskbar.d.ts +6 -3
  129. package/dist/types/components.d.ts +30 -0
  130. package/package.json +1 -1
  131. package/dist/sankhyablocks/p-0e279e7a.js +0 -1
  132. package/dist/sankhyablocks/p-3abeeefa.entry.js +0 -1
  133. package/dist/sankhyablocks/p-557368df.entry.js +0 -1
  134. package/dist/sankhyablocks/p-583151c5.entry.js +0 -1
  135. package/dist/sankhyablocks/p-8f73da95.js +0 -1
  136. package/dist/sankhyablocks/p-a2ed1ebd.entry.js +0 -1
  137. package/dist/sankhyablocks/p-a5108625.entry.js +0 -1
  138. package/dist/sankhyablocks/p-a644a956.js +0 -1
  139. package/dist/sankhyablocks/p-bb2f5f38.js +0 -1
@@ -5,16 +5,16 @@ const core = require('@sankhyalabs/core');
5
5
  const DataUnit = require('@sankhyalabs/core/dist/dataunit/DataUnit');
6
6
  const utils = require('@sankhyalabs/ezui/dist/collection/utils');
7
7
  const form = require('@sankhyalabs/ezui/dist/collection/utils/form');
8
- require('./DataFetcher-ed9d97ea.js');
9
- require('./ISave-81eb2fbc.js');
8
+ require('./DataFetcher-991b0349.js');
9
+ require('./ISave-ebf6b4ed.js');
10
10
  const index$1 = require('./index-e3e39724.js');
11
11
  require('@sankhyalabs/ezui/dist/collection/utils/constants');
12
12
  require('@sankhyalabs/core/dist/dataunit/metadata/UnitMetadata');
13
- require('./dataunit-fetcher-ab1cc071.js');
13
+ require('./dataunit-fetcher-8bf469e7.js');
14
14
  require('./filter-item-type.enum-a7ffdaa6.js');
15
- require('./form-config-fetcher-f0897eb5.js');
15
+ require('./form-config-fetcher-c7af90d8.js');
16
16
  const constants = require('./constants-6d82e405.js');
17
- const SnkFormConfigManager = require('./SnkFormConfigManager-6838389c.js');
17
+ const SnkFormConfigManager = require('./SnkFormConfigManager-cdbb29d4.js');
18
18
  const taskbarElements = require('./taskbar-elements-fb5d1e08.js');
19
19
  const taskbarProcessor = require('./taskbar-processor-2fba34a8.js');
20
20
 
@@ -25,10 +25,13 @@ const SnkGuidesViewer = class {
25
25
  constructor(hostRef) {
26
26
  index.registerInstance(this, hostRef);
27
27
  this.snkMasterFormConfigChange = index.createEvent(this, "snkMasterFormConfigChange", 7);
28
+ this.formConfigVisibilityChanged = index.createEvent(this, "formConfigVisibilityChanged", 7);
28
29
  this.exit = index.createEvent(this, "exit", 7);
29
30
  this.actionClick = index.createEvent(this, "actionClick", 7);
30
31
  this.formItemsReady = index.createEvent(this, "formItemsReady", 7);
31
32
  this._guideBuilders = new Map();
33
+ this.CUSTOM_GUIDE_ID_PREFIX = "CUSTOM_GUIDE_";
34
+ this.CUSTOM_GUIDE_DATA_CUSTOM_ID = "CUSTOM_GUIDE";
32
35
  this.dataUnit = undefined;
33
36
  this.dataState = undefined;
34
37
  this.configName = undefined;
@@ -47,6 +50,7 @@ const SnkGuidesViewer = class {
47
50
  this.enableGridInsert = false;
48
51
  this.ignoreReadOnlyFormFields = undefined;
49
52
  this.getCustomTitle = undefined;
53
+ this.customGuidesConfig = [];
50
54
  this._hasToCreateFieldSearch = true;
51
55
  this._breadcrumbItems = [];
52
56
  this._guides = undefined;
@@ -61,6 +65,9 @@ const SnkGuidesViewer = class {
61
65
  observeDataUnit() {
62
66
  this.loadGuides(true);
63
67
  }
68
+ observeFormConfigManager(value) {
69
+ this.formConfigVisibilityChanged.emit(!!value);
70
+ }
64
71
  observeDataState(newValue, oldValue) {
65
72
  var _a, _b, _c, _d, _e, _f;
66
73
  const newRecordsIds = (_b = (_a = newValue === null || newValue === void 0 ? void 0 : newValue.selectionInfo) === null || _a === void 0 ? void 0 : _a.recordIds) !== null && _b !== void 0 ? _b : (_c = newValue === null || newValue === void 0 ? void 0 : newValue.selectedRecord) === null || _c === void 0 ? void 0 : _c['__record__id__'];
@@ -159,7 +166,7 @@ const SnkGuidesViewer = class {
159
166
  if (!this._configManager.isLoaded) {
160
167
  return;
161
168
  }
162
- this._masterFormMetadata = form.buildFormMetadata(this.masterFormConfig, this.dataUnit, true);
169
+ this._masterFormMetadata = form.buildFormMetadata(this.masterFormConfig, this.dataUnit, true, this.customGuidesConfig);
163
170
  const allSheets = this._masterFormMetadata.getAllSheets();
164
171
  const currentRecord = this.dataUnit.getSelectedRecord();
165
172
  const disableDetails = this.hasToDisableDetails(currentRecord);
@@ -305,38 +312,67 @@ const SnkGuidesViewer = class {
305
312
  return `${this.entityPath}/${entityName}`;
306
313
  }
307
314
  getContent() {
308
- var _a, _b, _c, _d, _e;
309
315
  if (!this.selectedGuide) {
310
316
  return;
311
317
  }
312
318
  const guideId = this.selectedGuide.id;
313
- let content;
319
+ if (this.isCustomGuide(guideId)) {
320
+ return index.h("div", { "data-custom-id": `${this.CUSTOM_GUIDE_DATA_CUSTOM_ID}`, "data-reserved-slot-id": guideId, id: this.buildCustomGuideContainerId(guideId) });
321
+ }
314
322
  const levels = guideId.split("::");
315
323
  const currentLevel = levels.pop();
316
324
  const childEntityName = form.FormMetadata.getDetailName(currentLevel);
317
325
  let detailId = guideId;
318
- if (childEntityName || levels.length > 0) {
319
- let formName;
320
- let detailBranch;
321
- if (guideId.includes(FORM_NAME_PREFIX)) {
322
- [detailId, formName] = guideId.split(FORM_NAME_PREFIX);
323
- const pathSize = ((_a = this._breadcrumbItems) === null || _a === void 0 ? void 0 : _a.length) || 0;
324
- detailBranch = pathSize > 1 ? this._breadcrumbItems[pathSize - 2] : this.selectedGuide;
325
- }
326
- else {
327
- detailBranch = this.selectedGuide;
328
- }
329
- content = this.wrapDetail(levels, index.h("snk-detail-view", { ref: (ref) => this._currentDetail = ref, dataUnitName: this.getDataUnitName(levels, childEntityName), onSnkDetailGuidesChange: (evt) => this.updateGuide(evt.detail), entityName: childEntityName, selectedForm: formName, branchGuide: detailBranch, guideItemPath: this._breadcrumbItems, key: `detail${detailId}`, canEdit: this.canEdit, onSnkSwitchGuide: evt => this._guideNavigator.selectGuide(evt.detail), resourceID: this.resourceID, taskbarCustomContainerId: this.detailTaskbarCustomContainerId, customEditors: this._customEditors, customRenders: this._customRenders, presentationMode: this.presentationMode }));
326
+ if (this.isDetailGuide(childEntityName, levels)) {
327
+ return this.buildDetailGuideContent(guideId, detailId, levels, childEntityName);
328
+ }
329
+ return this.buildFormViewGuideContent(guideId);
330
+ }
331
+ buildCustomGuideContainerId(guideId) {
332
+ return `${this.CUSTOM_GUIDE_ID_PREFIX}${guideId}`;
333
+ }
334
+ buildFormViewGuideContent(cardId) {
335
+ var _a, _b, _c, _d;
336
+ const sheet = this._masterFormMetadata.getSheet(cardId);
337
+ if (!sheet)
338
+ return;
339
+ const cardConfig = (_b = (_a = this.masterFormConfig) === null || _a === void 0 ? void 0 : _a.cardsState) === null || _b === void 0 ? void 0 : _b.get(cardId);
340
+ return (index.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 == index$1.PresentationMode.SECONDARY && this.buildTaskBar()));
341
+ }
342
+ isDetailGuide(childEntityName, levels) {
343
+ return childEntityName || levels.length > 0;
344
+ }
345
+ buildDetailGuideContent(guideId, detailId, levels, childEntityName) {
346
+ var _a;
347
+ let formName;
348
+ let detailBranch;
349
+ if (guideId.includes(FORM_NAME_PREFIX)) {
350
+ [detailId, formName] = guideId.split(FORM_NAME_PREFIX);
351
+ const pathSize = ((_a = this._breadcrumbItems) === null || _a === void 0 ? void 0 : _a.length) || 0;
352
+ detailBranch = pathSize > 1 ? this._breadcrumbItems[pathSize - 2] : this.selectedGuide;
330
353
  }
331
354
  else {
332
- const cardId = this.selectedGuide.id;
333
- const sheet = this._masterFormMetadata.getSheet(cardId);
334
- if (sheet) {
335
- const cardConfig = (_c = (_b = this.masterFormConfig) === null || _b === void 0 ? void 0 : _b.cardsState) === null || _c === void 0 ? void 0 : _c.get(cardId);
336
- content = index.h("snk-form-view", { ref: ref => this._mainForm = ref, fixed: cardConfig === null || cardConfig === void 0 ? void 0 : cardConfig.fixed, summaryFields: (_e = (_d = this.masterFormConfig) === null || _d === void 0 ? void 0 : _d.summary) === null || _e === void 0 ? void 0 : _e.get(cardId), name: cardId, label: sheet.label, fields: sheet.fields, dataUnit: this.dataUnit, formMetadata: this._masterFormMetadata, recordsValidator: this.recordsValidator, fieldToFocus: this._fieldToGetFocus, key: guideId, onSnkRequestClearFieldToFocus: _ => this.clearFieldToFocusHandler(), customEditors: this._customEditors, fieldsProps: this._fieldsProps, fieldSearch: this._fieldSearch }, this.presentationMode == index$1.PresentationMode.SECONDARY && this.buildTaskBar());
337
- }
355
+ detailBranch = this.selectedGuide;
338
356
  }
339
- return content;
357
+ return this.wrapDetail(levels, index.h("snk-detail-view", { ref: (ref) => this._currentDetail = ref, dataUnitName: this.getDataUnitName(levels, childEntityName), onSnkDetailGuidesChange: (evt) => this.updateGuide(evt.detail), entityName: childEntityName, selectedForm: formName, branchGuide: detailBranch, guideItemPath: this._breadcrumbItems, key: `detail${detailId}`, canEdit: this.canEdit, onSnkSwitchGuide: evt => this._guideNavigator.selectGuide(evt.detail), resourceID: this.resourceID, taskbarCustomContainerId: this.detailTaskbarCustomContainerId, customEditors: this._customEditors, customRenders: this._customRenders, presentationMode: this.presentationMode }));
358
+ }
359
+ isCustomGuide(guideId) {
360
+ var _a;
361
+ return (_a = this.customGuidesConfig) === null || _a === void 0 ? void 0 : _a.map(g => g.id).includes(guideId);
362
+ }
363
+ attachCustomGuideInView() {
364
+ //As guias customizadas ficam em slots reservados na DOM e
365
+ // precisam ser acessadas via querySelector e colocadas no container correto na view.
366
+ var _a;
367
+ const guideId = (_a = this.selectedGuide) === null || _a === void 0 ? void 0 : _a.id;
368
+ if (!this.isCustomGuide(guideId))
369
+ return;
370
+ const customGuideSlot = document.querySelector(`#${guideId}`);
371
+ const customGuideElement = customGuideSlot === null || customGuideSlot === void 0 ? void 0 : customGuideSlot.firstElementChild;
372
+ const customGuideViewContainer = document.querySelector(`#${this.buildCustomGuideContainerId(guideId)}`);
373
+ if (!customGuideElement || !customGuideViewContainer)
374
+ return;
375
+ customGuideViewContainer.appendChild(customGuideElement);
340
376
  }
341
377
  onBreadcrumbClickHandler(item) {
342
378
  if ((item === null || item === void 0 ? void 0 : item.id) == undefined) {
@@ -419,7 +455,29 @@ const SnkGuidesViewer = class {
419
455
  this.addFormLegacyConfigName();
420
456
  this._configManager.loadConfig();
421
457
  }
458
+ componentWillRender() {
459
+ this.detachCustomGuideFromView();
460
+ }
461
+ detachCustomGuideFromView() {
462
+ // Antes de cada renderização, o componente remove a guia customizada da view
463
+ // e a coloca de volta no slot reservado na DOM para que não seja perdida sua referência.
464
+ if (!this.customGuidesConfig || this.customGuidesConfig.length === 0)
465
+ return;
466
+ const viewCustomGuideContainer = this._element.querySelector(`[data-custom-id="${this.CUSTOM_GUIDE_DATA_CUSTOM_ID}"]`);
467
+ const reservedSlotId = viewCustomGuideContainer === null || viewCustomGuideContainer === void 0 ? void 0 : viewCustomGuideContainer.getAttribute('data-reserved-slot-id');
468
+ if (!(viewCustomGuideContainer === null || viewCustomGuideContainer === void 0 ? void 0 : viewCustomGuideContainer.hasChildNodes()) || !reservedSlotId)
469
+ return;
470
+ const customGuideReservedSlot = document.querySelector(`#${reservedSlotId}`);
471
+ const customGuideElement = viewCustomGuideContainer === null || viewCustomGuideContainer === void 0 ? void 0 : viewCustomGuideContainer.firstElementChild;
472
+ if (!customGuideReservedSlot || !customGuideElement)
473
+ return;
474
+ customGuideReservedSlot.appendChild(customGuideElement);
475
+ }
422
476
  componentDidRender() {
477
+ var _a;
478
+ if (this.isCustomGuide((_a = this.selectedGuide) === null || _a === void 0 ? void 0 : _a.id)) {
479
+ this.attachCustomGuideInView();
480
+ }
423
481
  if (!this._guideHasChanged) {
424
482
  return;
425
483
  }
@@ -548,6 +606,9 @@ const SnkGuidesViewer = class {
548
606
  const labels = selectedRecords.map(record => this.messagesBuilder.getMessage("snkCrud.title", record));
549
607
  return `[${labels.join(", ")}]`;
550
608
  }
609
+ getCustomGuidesConfig() {
610
+ return this._currentDetail ? [] : this.customGuidesConfig;
611
+ }
551
612
  componentDidLoad() {
552
613
  this.dataUnit.subscribe(this.dataUnitActionHandler.bind(this));
553
614
  this.initKeyboardManager();
@@ -567,7 +628,7 @@ const SnkGuidesViewer = class {
567
628
  render() {
568
629
  var _a, _b;
569
630
  if (this._formEditorConfigManager != undefined) {
570
- return (index.h("snk-form-config", { ref: ref => this._container = ref, tabindex: -1, dataUnit: this._formEditorDataUnit, messagesBuilder: this.messagesBuilder, configManager: this._formEditorConfigManager, onConfigClose: () => this._formEditorConfigManager = null }));
631
+ return (index.h("snk-form-config", { ref: ref => this._container = ref, tabindex: -1, dataUnit: this._formEditorDataUnit, messagesBuilder: this.messagesBuilder, configManager: this._formEditorConfigManager, onConfigClose: () => this._formEditorConfigManager = null, customGuidesConfig: this.getCustomGuidesConfig() }));
571
632
  }
572
633
  if (!this.dataUnit || !this._configManager.isLoaded) {
573
634
  return;
@@ -593,6 +654,7 @@ const SnkGuidesViewer = class {
593
654
  get _element() { return index.getElement(this); }
594
655
  static get watchers() { return {
595
656
  "dataUnit": ["observeDataUnit"],
657
+ "_formEditorConfigManager": ["observeFormConfigManager"],
596
658
  "dataState": ["observeDataState"],
597
659
  "masterFormConfig": ["observeMasterFormConfig"]
598
660
  }; }
@@ -2,27 +2,27 @@
2
2
 
3
3
  Object.defineProperty(exports, '__esModule', { value: true });
4
4
 
5
- const snkGuidesViewer = require('./snk-guides-viewer-8b841753.js');
5
+ const snkGuidesViewer = require('./snk-guides-viewer-366d5c32.js');
6
6
  require('./index-1cf293c1.js');
7
7
  require('@sankhyalabs/core');
8
8
  require('@sankhyalabs/core/dist/dataunit/DataUnit');
9
9
  require('@sankhyalabs/ezui/dist/collection/utils');
10
10
  require('@sankhyalabs/ezui/dist/collection/utils/form');
11
- require('./DataFetcher-ed9d97ea.js');
11
+ require('./DataFetcher-991b0349.js');
12
12
  require('./PrintUtils-bcaeb82f.js');
13
13
  require('@sankhyalabs/core/dist/dataunit/metadata/UnitMetadata');
14
- require('./ISave-81eb2fbc.js');
14
+ require('./ISave-ebf6b4ed.js');
15
15
  require('./index-e3e39724.js');
16
16
  require('@sankhyalabs/ezui/dist/collection/utils/constants');
17
- require('./dataunit-fetcher-ab1cc071.js');
17
+ require('./dataunit-fetcher-8bf469e7.js');
18
18
  require('@sankhyalabs/ezui/dist/collection/components/ez-grid/utils');
19
19
  require('@sankhyalabs/core/dist/utils/SortingUtils');
20
20
  require('./ResourceIDUtils-5ff86aa7.js');
21
21
  require('./filter-item-type.enum-a7ffdaa6.js');
22
- require('./form-config-fetcher-f0897eb5.js');
22
+ require('./form-config-fetcher-c7af90d8.js');
23
23
  require('./constants-6d82e405.js');
24
- require('./SnkFormConfigManager-6838389c.js');
25
- require('./ConfigStorage-b29e31be.js');
24
+ require('./SnkFormConfigManager-cdbb29d4.js');
25
+ require('./ConfigStorage-72f34bd4.js');
26
26
  require('./taskbar-elements-fb5d1e08.js');
27
27
  require('./index-13d05f03.js');
28
28
  require('./taskbar-processor-2fba34a8.js');
@@ -5,13 +5,13 @@ Object.defineProperty(exports, '__esModule', { value: true });
5
5
  const index = require('./index-1cf293c1.js');
6
6
  const core = require('@sankhyalabs/core');
7
7
  const PersonalizedFilterUtils = require('./PersonalizedFilterUtils-7259cf65.js');
8
- const ConfigStorage = require('./ConfigStorage-b29e31be.js');
8
+ const ConfigStorage = require('./ConfigStorage-72f34bd4.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-13d05f03.js');
12
12
  require('./filter-item-type.enum-a7ffdaa6.js');
13
- require('./form-config-fetcher-f0897eb5.js');
14
- require('./DataFetcher-ed9d97ea.js');
13
+ require('./form-config-fetcher-c7af90d8.js');
14
+ require('./DataFetcher-991b0349.js');
15
15
  require('./PrintUtils-bcaeb82f.js');
16
16
  require('@sankhyalabs/core/dist/dataunit/metadata/UnitMetadata');
17
17
 
@@ -4,14 +4,14 @@ Object.defineProperty(exports, '__esModule', { value: true });
4
4
 
5
5
  const index = require('./index-1cf293c1.js');
6
6
  const core = require('@sankhyalabs/core');
7
- const ISave = require('./ISave-81eb2fbc.js');
8
- require('./DataFetcher-ed9d97ea.js');
7
+ const ISave = require('./ISave-ebf6b4ed.js');
8
+ require('./DataFetcher-991b0349.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-ab1cc071.js');
12
+ require('./dataunit-fetcher-8bf469e7.js');
13
13
  require('./filter-item-type.enum-a7ffdaa6.js');
14
- require('./form-config-fetcher-f0897eb5.js');
14
+ require('./form-config-fetcher-c7af90d8.js');
15
15
  require('./constants-6d82e405.js');
16
16
  require('./PrintUtils-bcaeb82f.js');
17
17
  require('@sankhyalabs/ezui/dist/collection/components/ez-grid/utils');
@@ -7,18 +7,18 @@ 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-fb5d1e08.js');
10
- require('./DataFetcher-ed9d97ea.js');
11
- require('./ISave-81eb2fbc.js');
12
- const SnkMultiSelectionListDataSource = require('./SnkMultiSelectionListDataSource-1e804147.js');
10
+ require('./DataFetcher-991b0349.js');
11
+ require('./ISave-ebf6b4ed.js');
12
+ const SnkMultiSelectionListDataSource = require('./SnkMultiSelectionListDataSource-011bec79.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-ab1cc071.js');
16
+ const dataunitFetcher = require('./dataunit-fetcher-8bf469e7.js');
17
17
  require('./filter-item-type.enum-a7ffdaa6.js');
18
- const formConfigFetcher = require('./form-config-fetcher-f0897eb5.js');
18
+ const formConfigFetcher = require('./form-config-fetcher-c7af90d8.js');
19
19
  const taskbarProcessor = require('./taskbar-processor-2fba34a8.js');
20
- const ConfigStorage = require('./ConfigStorage-b29e31be.js');
21
- const SnkFormConfigManager = require('./SnkFormConfigManager-6838389c.js');
20
+ const ConfigStorage = require('./ConfigStorage-72f34bd4.js');
21
+ const SnkFormConfigManager = require('./SnkFormConfigManager-cdbb29d4.js');
22
22
  const index$2 = require('./index-13d05f03.js');
23
23
  require('./PrintUtils-bcaeb82f.js');
24
24
  require('./GetSelectedRecordsIDsInfo-bd50caf1.js');
@@ -4,9 +4,9 @@ Object.defineProperty(exports, '__esModule', { value: true });
4
4
 
5
5
  const index = require('./index-1cf293c1.js');
6
6
  const core = require('@sankhyalabs/core');
7
+ const index$1 = require('./index-e3e39724.js');
7
8
  const AuthorizationConfig = require('./AuthorizationConfig-79ffae4b.js');
8
9
  const taskbarElements = require('./taskbar-elements-fb5d1e08.js');
9
- const index$1 = require('./index-e3e39724.js');
10
10
  require('./index-13d05f03.js');
11
11
 
12
12
  const snkTaskbarCss = ".sc-snk-taskbar-h{display:flex;flex-wrap:wrap}.no-wrap.sc-snk-taskbar-h{flex-wrap:nowrap}.full-width.sc-snk-taskbar-h{width:100%}.align-right.sc-snk-taskbar-h{justify-content:flex-end}.overflowed.sc-snk-taskbar{display:none}";
@@ -23,6 +23,7 @@ const SnkTaskbar = class {
23
23
  this.TASKBAR_CUSTOM_ELEMENTS = 'taskbar-custom-elements-container';
24
24
  this.TASKBAR_ADDITIONAL_SLOT_CONTAINER_CLASS_NAME = 'taskbar-additional-slot-container';
25
25
  this.TASKBAR_ADDITIONAL_SLOT = 'taskbar-additional-slot-container';
26
+ this._dataUnitInitialized = false;
26
27
  this._titleKeyByElement = {
27
28
  [taskbarElements.TaskbarElement.UPDATE_MULTIPLE]: "snkTaskbar.titleUpdateMultiple",
28
29
  [taskbarElements.TaskbarElement.UPDATE]: "snkTaskbar.titleUpdate",
@@ -121,6 +122,17 @@ const SnkTaskbar = class {
121
122
  this.taskbarSaveUnlocker.emit();
122
123
  }
123
124
  }
125
+ observeDataUnit(newValue) {
126
+ this.initializeDataUnit(newValue);
127
+ }
128
+ initializeDataUnit(dataUnit) {
129
+ if (!!dataUnit && !this._dataUnitInitialized) {
130
+ this._dataUnitInitialized = true;
131
+ const dataInfo = { dataUnit: this.dataUnit };
132
+ core.ElementIDUtils.addIDInfo(this._element, null, dataInfo);
133
+ this.dataUnit.subscribe(this.onSaveEvent);
134
+ }
135
+ }
124
136
  // Internal methods
125
137
  elementsFromString(strButtons) {
126
138
  const elements = [];
@@ -166,45 +178,46 @@ const SnkTaskbar = class {
166
178
  }
167
179
  elementClick(elem) {
168
180
  core.LockManager.whenResolve(this._element, core.LockManagerOperation.TASKBAR_CLICK).then(() => {
169
- if (this.dataUnit) {
170
- switch (elem) {
171
- case taskbarElements.TaskbarElement.PREVIOUS:
172
- this.dataUnit.previousRecord();
173
- break;
174
- case taskbarElements.TaskbarElement.NEXT:
175
- this.dataUnit.nextRecord();
176
- break;
177
- case taskbarElements.TaskbarElement.REFRESH:
178
- this.dataUnit.loadData();
179
- break;
180
- case taskbarElements.TaskbarElement.CLONE:
181
- this.dataUnit.copySelected();
182
- break;
183
- case taskbarElements.TaskbarElement.REMOVE:
184
- this.dataUnit.removeSelectedRecords();
185
- break;
186
- case taskbarElements.TaskbarElement.INSERT:
187
- this.dataUnit.addRecord();
188
- break;
189
- case taskbarElements.TaskbarElement.CANCEL:
190
- this.dataUnit.cancelEdition();
191
- break;
192
- case taskbarElements.TaskbarElement.SAVE:
193
- if (!this._isWaitingForSave) {
194
- this._isWaitingForSave = true;
195
- this.dataUnit.saveData().catch((err) => {
196
- if (err instanceof core.SilentException) {
197
- return;
198
- }
199
- else {
200
- throw err;
201
- }
202
- }).finally(() => {
203
- this._isWaitingForSave = false;
204
- });
205
- }
206
- break;
207
- }
181
+ if (!this.dataUnit) {
182
+ return;
183
+ }
184
+ switch (elem) {
185
+ case taskbarElements.TaskbarElement.PREVIOUS:
186
+ this.dataUnit.previousRecord();
187
+ break;
188
+ case taskbarElements.TaskbarElement.NEXT:
189
+ this.dataUnit.nextRecord();
190
+ break;
191
+ case taskbarElements.TaskbarElement.REFRESH:
192
+ this.dataUnit.loadData();
193
+ break;
194
+ case taskbarElements.TaskbarElement.CLONE:
195
+ this.dataUnit.copySelected();
196
+ break;
197
+ case taskbarElements.TaskbarElement.REMOVE:
198
+ this.dataUnit.removeSelectedRecords();
199
+ break;
200
+ case taskbarElements.TaskbarElement.INSERT:
201
+ this.dataUnit.addRecord();
202
+ break;
203
+ case taskbarElements.TaskbarElement.CANCEL:
204
+ this.dataUnit.cancelEdition();
205
+ break;
206
+ case taskbarElements.TaskbarElement.SAVE:
207
+ if (!this._isWaitingForSave) {
208
+ this._isWaitingForSave = true;
209
+ this.dataUnit.saveData().catch((err) => {
210
+ if (err instanceof core.SilentException) {
211
+ return;
212
+ }
213
+ else {
214
+ throw err;
215
+ }
216
+ }).finally(() => {
217
+ this._isWaitingForSave = false;
218
+ });
219
+ }
220
+ break;
208
221
  }
209
222
  if (this.isEnabled(elem))
210
223
  this.actionClick.emit(elem);
@@ -403,10 +416,8 @@ const SnkTaskbar = class {
403
416
  };
404
417
  }
405
418
  componentDidLoad() {
406
- const dataInfo = { dataUnit: this.dataUnit };
407
- core.ElementIDUtils.addIDInfo(this._element, null, dataInfo);
419
+ this.initializeDataUnit(this.dataUnit);
408
420
  this.handleOverFlowStrategy();
409
- this.dataUnit.subscribe(this.onSaveEvent);
410
421
  }
411
422
  componentDidRender() {
412
423
  this.appendCustomElementsInTaskbar();
@@ -466,7 +477,8 @@ const SnkTaskbar = class {
466
477
  "buttons": ["observeButtons"],
467
478
  "disabledButtons": ["observeDisabledButtons"],
468
479
  "_lastWidth": ["observeLastWidth"],
469
- "_isWaitingForSave": ["observeIsWaitingForSave"]
480
+ "_isWaitingForSave": ["observeIsWaitingForSave"],
481
+ "dataUnit": ["observeDataUnit"]
470
482
  }; }
471
483
  };
472
484
  SnkTaskbar.style = snkTaskbarCss;
@@ -11,10 +11,10 @@
11
11
  "./components/snk-actions-button/subcomponents/snk-client-confirm.js",
12
12
  "./components/snk-attach/snk-attach.js",
13
13
  "./components/snk-configurator/snk-configurator.js",
14
+ "./components/snk-crud/subcomponents/snk-guides-viewer.js",
14
15
  "./components/snk-crud/snk-crud.js",
15
16
  "./components/snk-crud/subcomponents/snk-form-summary.js",
16
17
  "./components/snk-crud/subcomponents/snk-form-view.js",
17
- "./components/snk-crud/subcomponents/snk-guides-viewer.js",
18
18
  "./components/snk-crud/subcomponents/snk-detail-view/snk-detail-view.js",
19
19
  "./components/snk-custom-slot-elements/snk-custom-slot-elements.js",
20
20
  "./components/snk-data-exporter/snk-data-exporter.js",
@@ -58,6 +58,7 @@ export class SnkCrud {
58
58
  };
59
59
  this._dataUnit = undefined;
60
60
  this._dataState = undefined;
61
+ this._suppressEntitySearch = false;
61
62
  this.attachmentRegisterKey = undefined;
62
63
  this._currentViewMode = VIEW_MODE.GRID;
63
64
  this._canEdit = undefined;
@@ -94,6 +95,7 @@ export class SnkCrud {
94
95
  this.layoutFormConfig = true;
95
96
  this.multipleEditionEnabled = true;
96
97
  this.paginationCounterMode = 'auto';
98
+ this.customGuidesConfig = [];
97
99
  this.showEntitySearch = true;
98
100
  this.disableNumberingConfig = false;
99
101
  }
@@ -542,7 +544,7 @@ export class SnkCrud {
542
544
  }
543
545
  renderDynamicSearch(slotName) {
544
546
  var _a;
545
- if (!this.showEntitySearch || ((_a = this._dataState) === null || _a === void 0 ? void 0 : _a.insertionMode) === true)
547
+ if (this._suppressEntitySearch || !this.showEntitySearch || ((_a = this._dataState) === null || _a === void 0 ? void 0 : _a.insertionMode) === true)
546
548
  return;
547
549
  return (h("div", { slot: slotName, class: "entity-search-container", style: { position: 'relative', display: 'inline-block', marginLeft: '10px', minWidth: '200px' } }, h("ez-search", { label: "Buscar registros", optionLoader: this.loadEntitySuggestions, onEzChange: (evt) => this.searchEntitySelect(evt.detail), mode: "slim", showMore: this._showMoreOnSearch, suppressEmptyOption: true, suppressInputPersist: true })));
548
550
  }
@@ -551,7 +553,7 @@ export class SnkCrud {
551
553
  return;
552
554
  }
553
555
  this._snkDataUnit.ignoreSaveMessage = (this._currentViewMode === VIEW_MODE.GRID && !this.enableGridInsert);
554
- return (h(Host, null, h("ez-view-stack", { ref: (ref) => this._viewStack = ref, "data-element-id": "crud" }, h("stack-item", { class: 'ez-flex ez-flex--column ez-size-height--full ez-size-width--full ez-padding--medium' }, h("snk-grid", { ref: (ref) => this._snkGrid = ref, class: 'ez-flex ez-flex--column ez-size-height--full ez-size-width--full', filterBarTitle: this.filterBarTitle, "data-element-id": "crud_grid", configName: this.configName, onGridDoubleClick: () => this.gridToForm(true), taskbarManager: this.taskbarManager, onActionClick: evt => this.executeAction(evt.detail), messagesBuilder: this.messagesBuilder, actionsList: this.actionsList, statusResolver: this.statusResolver, multipleSelection: this.multipleSelection, presentationMode: this.presentationMode, recordsValidator: this.recordsValidator, selectionToastConfig: this.selectionToastConfig, useEnterLikeTab: this.useEnterLikeTab, canEdit: this._canEdit, resourceID: this._resourceID, disablePersonalizedFilter: this.disablePersonalizedFilter, gridLegacyConfigName: this.gridLegacyConfigName, filterBarLegacyConfigName: this.filterBarLegacyConfigName, autoLoad: this.autoLoad, autoFocus: this.autoFocus, enableGridInsert: this.enableGridInsert, enableLockManagerTaskbarClick: this.enableLockManagerTaskbarClick, enableLockManagerLoadingComp: this.enableLockManagerLoadingComp, strategyExporter: this.strategyExporter, multipleEditionEnabled: this.multipleEditionEnabled, paginationCounterMode: this.paginationCounterMode }, h("slot", { name: "GRID_TASKBAR_CUSTOM_ELEMENTS" }), h("slot", { name: "GRID_HEADER_CUSTOM_ELEMENTS" }), h("slot", { name: "SnkGridHeader" }), h("slot", { name: "SnkGridFooter" }), h("slot", { name: "SnkGridTaskBar" }), this.renderDynamicSearch("GRID_HEADER_DYNAMIC_SEARCH"))), h("stack-item", null, h("snk-guides-viewer", { ref: ref => this._guidesViewer = ref, entityPath: this._snkDataUnit.entityName, messagesBuilder: this.messagesBuilder, onExit: () => this.setViewMode(VIEW_MODE.GRID), dataState: this._dataState, dataUnit: this._dataUnit, actionsList: this.actionsList, taskbarManager: this.taskbarManager, configName: this.configName, onActionClick: evt => this.executeAction(evt.detail), presentationMode: this.presentationMode, "data-element-id": "crud_form", canEdit: this._canEdit, recordsValidator: this.recordsValidator, resourceID: this._resourceID, detailTaskbarCustomContainerId: this.customContainerId, formLegacyConfigName: this.formLegacyConfigName, enableGridInsert: this.enableGridInsert, getCustomTitle: this.setCustomFormTitle, ignoreReadOnlyFormFields: this.ignoreReadOnlyFormFields }, h("slot", { name: "GUIDES_VIEWER_TASKBAR_CUSTOM_ELEMENTS" }), this.renderDynamicSearch("GUIDES_VIEWER_DYNAMIC_SEARCH"), h("slot", { name: "SnkFormTaskBar" }))), h("stack-item", { tabIndex: "0" }, h("snk-attach", { registerKey: this.attachmentRegisterKey, messagesBuilder: this.messagesBuilder, entityName: this._snkDataUnit.entityName, onBack: this.backView.bind(this) })), h("snk-configurator", { ref: (ref) => this._snkConfigurator = ref, entityName: this._snkDataUnit.entityName, viewMode: this._currentViewMode, messagesBuilder: this.messagesBuilder, onConfigSelected: (evt) => this.setViewMode(evt.detail), onOpenConfig: (evt) => this.openConfig(evt.detail), showActionButtons: this.showActionButtons, onSave: evt => this.handleConfiguratorEvent(evt, 'SAVE'), onCancel: evt => this.handleConfiguratorEvent(evt, 'CANCEL'), resourceID: this._resourceID, customContainerId: this.customContainerId, layoutFormConfig: this.layoutFormConfig })), h("div", { id: `${this.customContainerId}` }, h("slot", { name: "SnkConfigContainerSlot" }), h("slot", { name: "DETAIL_GRID_HEADER_CUSTOM_ELEMENTS" }), h("slot", { name: "DETAIL_GRID_TASKBAR_CUSTOM_ELEMENTS" }), h("slot", { name: "DETAIL_TASKBAR_CUSTOM_ELEMENTS" }))));
556
+ return (h(Host, null, h("ez-view-stack", { ref: (ref) => this._viewStack = ref, "data-element-id": "crud" }, h("stack-item", { class: 'ez-flex ez-flex--column ez-size-height--full ez-size-width--full ez-padding--medium' }, h("snk-grid", { ref: (ref) => this._snkGrid = ref, class: 'ez-flex ez-flex--column ez-size-height--full ez-size-width--full', filterBarTitle: this.filterBarTitle, "data-element-id": "crud_grid", configName: this.configName, onGridDoubleClick: () => this.gridToForm(true), taskbarManager: this.taskbarManager, onActionClick: evt => this.executeAction(evt.detail), messagesBuilder: this.messagesBuilder, actionsList: this.actionsList, statusResolver: this.statusResolver, multipleSelection: this.multipleSelection, presentationMode: this.presentationMode, recordsValidator: this.recordsValidator, selectionToastConfig: this.selectionToastConfig, useEnterLikeTab: this.useEnterLikeTab, canEdit: this._canEdit, resourceID: this._resourceID, disablePersonalizedFilter: this.disablePersonalizedFilter, gridLegacyConfigName: this.gridLegacyConfigName, filterBarLegacyConfigName: this.filterBarLegacyConfigName, autoLoad: this.autoLoad, autoFocus: this.autoFocus, enableGridInsert: this.enableGridInsert, enableLockManagerTaskbarClick: this.enableLockManagerTaskbarClick, enableLockManagerLoadingComp: this.enableLockManagerLoadingComp, strategyExporter: this.strategyExporter, multipleEditionEnabled: this.multipleEditionEnabled, paginationCounterMode: this.paginationCounterMode }, h("slot", { name: "GRID_TASKBAR_CUSTOM_ELEMENTS" }), h("slot", { name: "GRID_HEADER_CUSTOM_ELEMENTS" }), h("slot", { name: "SnkGridHeader" }), h("slot", { name: "SnkGridFooter" }), h("slot", { name: "SnkGridTaskBar" }), this.renderDynamicSearch("GRID_HEADER_DYNAMIC_SEARCH"))), h("stack-item", null, h("snk-guides-viewer", { ref: ref => this._guidesViewer = ref, customGuidesConfig: this.customGuidesConfig, entityPath: this._snkDataUnit.entityName, messagesBuilder: this.messagesBuilder, onExit: () => this.setViewMode(VIEW_MODE.GRID), dataState: this._dataState, dataUnit: this._dataUnit, actionsList: this.actionsList, taskbarManager: this.taskbarManager, configName: this.configName, onActionClick: evt => this.executeAction(evt.detail), onFormConfigVisibilityChanged: evt => this._suppressEntitySearch = evt.detail, presentationMode: this.presentationMode, "data-element-id": "crud_form", canEdit: this._canEdit, recordsValidator: this.recordsValidator, resourceID: this._resourceID, detailTaskbarCustomContainerId: this.customContainerId, formLegacyConfigName: this.formLegacyConfigName, enableGridInsert: this.enableGridInsert, getCustomTitle: this.setCustomFormTitle, ignoreReadOnlyFormFields: this.ignoreReadOnlyFormFields }, h("slot", { name: "GUIDES_VIEWER_TASKBAR_CUSTOM_ELEMENTS" }), this.renderDynamicSearch("GUIDES_VIEWER_DYNAMIC_SEARCH"), h("slot", { name: "SnkFormTaskBar" }))), h("stack-item", { tabIndex: "0" }, h("snk-attach", { registerKey: this.attachmentRegisterKey, messagesBuilder: this.messagesBuilder, entityName: this._snkDataUnit.entityName, onBack: this.backView.bind(this) })), h("snk-configurator", { ref: (ref) => this._snkConfigurator = ref, entityName: this._snkDataUnit.entityName, viewMode: this._currentViewMode, messagesBuilder: this.messagesBuilder, onConfigSelected: (evt) => this.setViewMode(evt.detail), onOpenConfig: (evt) => this.openConfig(evt.detail), showActionButtons: this.showActionButtons, onSave: evt => this.handleConfiguratorEvent(evt, 'SAVE'), onCancel: evt => this.handleConfiguratorEvent(evt, 'CANCEL'), resourceID: this._resourceID, customContainerId: this.customContainerId, layoutFormConfig: this.layoutFormConfig })), h("div", { id: `${this.customContainerId}` }, h("slot", { name: "SnkConfigContainerSlot" }), h("slot", { name: "DETAIL_GRID_HEADER_CUSTOM_ELEMENTS" }), h("slot", { name: "DETAIL_GRID_TASKBAR_CUSTOM_ELEMENTS" }), h("slot", { name: "DETAIL_TASKBAR_CUSTOM_ELEMENTS" }))));
555
557
  }
556
558
  static get is() { return "snk-crud"; }
557
559
  static get encapsulation() { return "scoped"; }
@@ -1088,6 +1090,30 @@ export class SnkCrud {
1088
1090
  "reflect": false,
1089
1091
  "defaultValue": "'auto'"
1090
1092
  },
1093
+ "customGuidesConfig": {
1094
+ "type": "unknown",
1095
+ "mutable": false,
1096
+ "complexType": {
1097
+ "original": "Array<CustomGuideItem>",
1098
+ "resolved": "CustomGuideItem[]",
1099
+ "references": {
1100
+ "Array": {
1101
+ "location": "global"
1102
+ },
1103
+ "CustomGuideItem": {
1104
+ "location": "import",
1105
+ "path": "./subcomponents/snk-guides-viewer"
1106
+ }
1107
+ }
1108
+ },
1109
+ "required": false,
1110
+ "optional": true,
1111
+ "docs": {
1112
+ "tags": [],
1113
+ "text": "Fornece as informa\u00E7\u00F5es das guias personalizadas."
1114
+ },
1115
+ "defaultValue": "[]"
1116
+ },
1091
1117
  "showEntitySearch": {
1092
1118
  "type": "boolean",
1093
1119
  "mutable": false,
@@ -1130,6 +1156,7 @@ export class SnkCrud {
1130
1156
  return {
1131
1157
  "_dataUnit": {},
1132
1158
  "_dataState": {},
1159
+ "_suppressEntitySearch": {},
1133
1160
  "attachmentRegisterKey": {},
1134
1161
  "_currentViewMode": {},
1135
1162
  "_canEdit": {},