@fmsim/board 1.0.70 → 1.0.71

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.
@@ -2,6 +2,91 @@
2
2
  "schemaVersion": "1.0.0",
3
3
  "readme": "",
4
4
  "modules": [
5
+ {
6
+ "kind": "javascript-module",
7
+ "path": "stories/restful-attachment-selector.stories.ts",
8
+ "declarations": [
9
+ {
10
+ "kind": "variable",
11
+ "name": "meta",
12
+ "default": "{ title: 'Components/RestfulAttachmentSelector', component: 'restful-attachment-selector', argTypes: { category: { control: 'select', options: ['', 'audio', 'video', 'image', 'text', 'application'], description: '첨부파일 카테고리' }, creatable: { control: 'boolean', description: '파일 업로드 가능 여부' }, userName: { control: 'text', description: '사용자 이름' } }, parameters: { layout: 'centered' } } satisfies Meta"
13
+ },
14
+ {
15
+ "kind": "variable",
16
+ "name": "Default",
17
+ "type": {
18
+ "text": "Story"
19
+ },
20
+ "default": "{ render: args => html` <restful-attachment-selector .category=${args.category} .creatable=${args.creatable} .userName=${args.userName} style=\"width: 800px; height: 600px;\" ></restful-attachment-selector> `, args: { category: '', creatable: true, userName: 'testUser' } }"
21
+ },
22
+ {
23
+ "kind": "variable",
24
+ "name": "WithCategory",
25
+ "type": {
26
+ "text": "Story"
27
+ },
28
+ "default": "{ ...Default, args: { ...Default.args, category: 'document' } }"
29
+ },
30
+ {
31
+ "kind": "variable",
32
+ "name": "ReadOnly",
33
+ "type": {
34
+ "text": "Story"
35
+ },
36
+ "default": "{ ...Default, args: { ...Default.args, creatable: false } }"
37
+ },
38
+ {
39
+ "kind": "variable",
40
+ "name": "WithTestData",
41
+ "type": {
42
+ "text": "Story"
43
+ },
44
+ "default": "{ ...Default, args: { ...Default.args, category: 'document' }, play: async ({ canvasElement }) => { const selector = canvasElement.querySelector('restful-attachment-selector') as RestfulAttachmentSelector if (selector) { // 테스트 데이터 주입 selector.attachments = [ { id: 'test-1', name: 'test1.txt', description: 'Test file 1', mimetype: 'text/plain', encoding: '7bit', category: 'document', path: 'test1.txt', bulk: '27', createdAt: new Date().toISOString(), updatedAt: new Date().toISOString(), creatorId: 'testUser', updaterId: 'testUser', fullpath: 'http://localhost:16060/mcs/lv/images/test1.txt', download: 'http://localhost:16060/mcs/lv/downloadFile/test1.txt' }, { id: 'test-2', name: 'test2.jpg', description: 'Test image', mimetype: 'image/jpeg', encoding: '7bit', category: 'image', path: 'test2.jpg', bulk: '1024', createdAt: new Date().toISOString(), updatedAt: new Date().toISOString(), creatorId: 'testUser', updaterId: 'testUser', fullpath: 'http://localhost:16060/mcs/lv/images/test2.jpg', download: 'http://localhost:16060/mcs/lv/downloadFile/test2.jpg' } ] } } }"
45
+ }
46
+ ],
47
+ "exports": [
48
+ {
49
+ "kind": "js",
50
+ "name": "default",
51
+ "declaration": {
52
+ "name": "meta",
53
+ "module": "stories/restful-attachment-selector.stories.ts"
54
+ }
55
+ },
56
+ {
57
+ "kind": "js",
58
+ "name": "Default",
59
+ "declaration": {
60
+ "name": "Default",
61
+ "module": "stories/restful-attachment-selector.stories.ts"
62
+ }
63
+ },
64
+ {
65
+ "kind": "js",
66
+ "name": "WithCategory",
67
+ "declaration": {
68
+ "name": "WithCategory",
69
+ "module": "stories/restful-attachment-selector.stories.ts"
70
+ }
71
+ },
72
+ {
73
+ "kind": "js",
74
+ "name": "ReadOnly",
75
+ "declaration": {
76
+ "name": "ReadOnly",
77
+ "module": "stories/restful-attachment-selector.stories.ts"
78
+ }
79
+ },
80
+ {
81
+ "kind": "js",
82
+ "name": "WithTestData",
83
+ "declaration": {
84
+ "name": "WithTestData",
85
+ "module": "stories/restful-attachment-selector.stories.ts"
86
+ }
87
+ }
88
+ ]
89
+ },
5
90
  {
6
91
  "kind": "javascript-module",
7
92
  "path": "src/index.ts",
@@ -1036,6 +1121,22 @@
1036
1121
  "kind": "field",
1037
1122
  "name": "fmbHideLegendHandler"
1038
1123
  },
1124
+ {
1125
+ "kind": "field",
1126
+ "name": "fmbShowPopupHandler"
1127
+ },
1128
+ {
1129
+ "kind": "field",
1130
+ "name": "fmbHidePopupHandler"
1131
+ },
1132
+ {
1133
+ "kind": "field",
1134
+ "name": "fmbShowFloatingContainerHandler"
1135
+ },
1136
+ {
1137
+ "kind": "field",
1138
+ "name": "fmbHideFloatingContainerHandler"
1139
+ },
1039
1140
  {
1040
1141
  "kind": "field",
1041
1142
  "name": "clickComponentHandler"
@@ -1682,85 +1783,92 @@
1682
1783
  },
1683
1784
  {
1684
1785
  "kind": "javascript-module",
1685
- "path": "stories/restful-attachment-selector.stories.ts",
1786
+ "path": "src/data-storage/data-storage.ts",
1686
1787
  "declarations": [
1687
1788
  {
1688
- "kind": "variable",
1689
- "name": "meta",
1690
- "default": "{ title: 'Components/RestfulAttachmentSelector', component: 'restful-attachment-selector', argTypes: { category: { control: 'select', options: ['', 'audio', 'video', 'image', 'text', 'application'], description: '첨부파일 카테고리' }, creatable: { control: 'boolean', description: '파일 업로드 가능 여부' }, userName: { control: 'text', description: '사용자 이름' } }, parameters: { layout: 'centered' } } satisfies Meta"
1691
- },
1692
- {
1693
- "kind": "variable",
1694
- "name": "Default",
1695
- "type": {
1696
- "text": "Story"
1697
- },
1698
- "default": "{ render: args => html` <restful-attachment-selector .category=${args.category} .creatable=${args.creatable} .userName=${args.userName} style=\"width: 800px; height: 600px;\" ></restful-attachment-selector> `, args: { category: '', creatable: true, userName: 'testUser' } }"
1699
- },
1700
- {
1701
- "kind": "variable",
1702
- "name": "WithCategory",
1703
- "type": {
1704
- "text": "Story"
1705
- },
1706
- "default": "{ ...Default, args: { ...Default.args, category: 'document' } }"
1707
- },
1708
- {
1709
- "kind": "variable",
1710
- "name": "ReadOnly",
1711
- "type": {
1712
- "text": "Story"
1713
- },
1714
- "default": "{ ...Default, args: { ...Default.args, creatable: false } }"
1715
- },
1716
- {
1717
- "kind": "variable",
1718
- "name": "WithTestData",
1719
- "type": {
1720
- "text": "Story"
1721
- },
1722
- "default": "{ ...Default, args: { ...Default.args, category: 'document' }, play: async ({ canvasElement }) => { const selector = canvasElement.querySelector('restful-attachment-selector') as RestfulAttachmentSelector if (selector) { // 테스트 데이터 주입 selector.attachments = [ { id: 'test-1', name: 'test1.txt', description: 'Test file 1', mimetype: 'text/plain', encoding: '7bit', category: 'document', path: 'test1.txt', bulk: '27', createdAt: new Date().toISOString(), updatedAt: new Date().toISOString(), creatorId: 'testUser', updaterId: 'testUser', fullpath: 'http://localhost:16060/mcs/lv/images/test1.txt', download: 'http://localhost:16060/mcs/lv/downloadFile/test1.txt' }, { id: 'test-2', name: 'test2.jpg', description: 'Test image', mimetype: 'image/jpeg', encoding: '7bit', category: 'image', path: 'test2.jpg', bulk: '1024', createdAt: new Date().toISOString(), updatedAt: new Date().toISOString(), creatorId: 'testUser', updaterId: 'testUser', fullpath: 'http://localhost:16060/mcs/lv/images/test2.jpg', download: 'http://localhost:16060/mcs/lv/downloadFile/test2.jpg' } ] } } }"
1789
+ "kind": "class",
1790
+ "description": "",
1791
+ "name": "DataStorage",
1792
+ "members": [
1793
+ {
1794
+ "kind": "field",
1795
+ "name": "id",
1796
+ "type": {
1797
+ "text": "string"
1798
+ },
1799
+ "privacy": "private",
1800
+ "default": "id"
1801
+ },
1802
+ {
1803
+ "kind": "method",
1804
+ "name": "load",
1805
+ "privacy": "public",
1806
+ "return": {
1807
+ "type": {
1808
+ "text": "Promise<any>"
1809
+ }
1810
+ },
1811
+ "parameters": [
1812
+ {
1813
+ "name": "key",
1814
+ "type": {
1815
+ "text": "Component"
1816
+ }
1817
+ }
1818
+ ]
1819
+ },
1820
+ {
1821
+ "kind": "method",
1822
+ "name": "save",
1823
+ "privacy": "public",
1824
+ "return": {
1825
+ "type": {
1826
+ "text": "Promise<void>"
1827
+ }
1828
+ },
1829
+ "parameters": [
1830
+ {
1831
+ "name": "key",
1832
+ "type": {
1833
+ "text": "Component"
1834
+ }
1835
+ },
1836
+ {
1837
+ "name": "value",
1838
+ "type": {
1839
+ "text": "any"
1840
+ }
1841
+ }
1842
+ ]
1843
+ },
1844
+ {
1845
+ "kind": "method",
1846
+ "name": "clear",
1847
+ "privacy": "public",
1848
+ "return": {
1849
+ "type": {
1850
+ "text": "Promise<void>"
1851
+ }
1852
+ },
1853
+ "parameters": [
1854
+ {
1855
+ "name": "key",
1856
+ "type": {
1857
+ "text": "Component"
1858
+ }
1859
+ }
1860
+ ]
1861
+ }
1862
+ ]
1723
1863
  }
1724
1864
  ],
1725
1865
  "exports": [
1726
1866
  {
1727
1867
  "kind": "js",
1728
- "name": "default",
1729
- "declaration": {
1730
- "name": "meta",
1731
- "module": "stories/restful-attachment-selector.stories.ts"
1732
- }
1733
- },
1734
- {
1735
- "kind": "js",
1736
- "name": "Default",
1737
- "declaration": {
1738
- "name": "Default",
1739
- "module": "stories/restful-attachment-selector.stories.ts"
1740
- }
1741
- },
1742
- {
1743
- "kind": "js",
1744
- "name": "WithCategory",
1745
- "declaration": {
1746
- "name": "WithCategory",
1747
- "module": "stories/restful-attachment-selector.stories.ts"
1748
- }
1749
- },
1750
- {
1751
- "kind": "js",
1752
- "name": "ReadOnly",
1753
- "declaration": {
1754
- "name": "ReadOnly",
1755
- "module": "stories/restful-attachment-selector.stories.ts"
1756
- }
1757
- },
1758
- {
1759
- "kind": "js",
1760
- "name": "WithTestData",
1868
+ "name": "DataStorage",
1761
1869
  "declaration": {
1762
- "name": "WithTestData",
1763
- "module": "stories/restful-attachment-selector.stories.ts"
1870
+ "name": "DataStorage",
1871
+ "module": "src/data-storage/data-storage.ts"
1764
1872
  }
1765
1873
  }
1766
1874
  ]
@@ -2867,98 +2975,6 @@
2867
2975
  }
2868
2976
  ]
2869
2977
  },
2870
- {
2871
- "kind": "javascript-module",
2872
- "path": "src/data-storage/data-storage.ts",
2873
- "declarations": [
2874
- {
2875
- "kind": "class",
2876
- "description": "",
2877
- "name": "DataStorage",
2878
- "members": [
2879
- {
2880
- "kind": "field",
2881
- "name": "id",
2882
- "type": {
2883
- "text": "string"
2884
- },
2885
- "privacy": "private",
2886
- "default": "id"
2887
- },
2888
- {
2889
- "kind": "method",
2890
- "name": "load",
2891
- "privacy": "public",
2892
- "return": {
2893
- "type": {
2894
- "text": "Promise<any>"
2895
- }
2896
- },
2897
- "parameters": [
2898
- {
2899
- "name": "key",
2900
- "type": {
2901
- "text": "Component"
2902
- }
2903
- }
2904
- ]
2905
- },
2906
- {
2907
- "kind": "method",
2908
- "name": "save",
2909
- "privacy": "public",
2910
- "return": {
2911
- "type": {
2912
- "text": "Promise<void>"
2913
- }
2914
- },
2915
- "parameters": [
2916
- {
2917
- "name": "key",
2918
- "type": {
2919
- "text": "Component"
2920
- }
2921
- },
2922
- {
2923
- "name": "value",
2924
- "type": {
2925
- "text": "any"
2926
- }
2927
- }
2928
- ]
2929
- },
2930
- {
2931
- "kind": "method",
2932
- "name": "clear",
2933
- "privacy": "public",
2934
- "return": {
2935
- "type": {
2936
- "text": "Promise<void>"
2937
- }
2938
- },
2939
- "parameters": [
2940
- {
2941
- "name": "key",
2942
- "type": {
2943
- "text": "Component"
2944
- }
2945
- }
2946
- ]
2947
- }
2948
- ]
2949
- }
2950
- ],
2951
- "exports": [
2952
- {
2953
- "kind": "js",
2954
- "name": "DataStorage",
2955
- "declaration": {
2956
- "name": "DataStorage",
2957
- "module": "src/data-storage/data-storage.ts"
2958
- }
2959
- }
2960
- ]
2961
- },
2962
2978
  {
2963
2979
  "kind": "javascript-module",
2964
2980
  "path": "src/layers/mcs-mouse-event-handler.ts",
@@ -29,8 +29,6 @@ export class PropertyEventTap extends LitElement {
29
29
  <option value="link-move">move to target link</option>
30
30
  <option value="data-toggle">toggle data</option>
31
31
  <option value="legend-toggle">toggle legend</option>
32
- <option value="popup">popup target board</option>
33
- <option value="modal-popup">modal popup target board</option>
34
32
  </select>
35
33
 
36
34
  <label> <ox-i18n msgid="label.target">target</ox-i18n> </label>
@@ -1 +1 @@
1
- {"version":3,"file":"property-event-tap.js","sourceRoot":"","sources":["../../../../../src/modeller/property-sidebar/effects/property-event-tap.ts"],"names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AAK,OAAO,IAAI,GAAG,KAAK,QAAQ,EAAE,CAAC;YACxC,IAAI,EAAE,OAAO,GAAG,EAAE,EAAE,GAAG,IAAI,CAAC,KAAK,IAAI,EAAE,CAAA;YAEvC,IAAI,CAAC,KAAK,GAAG;gBACX,GAAG,IAAI,CAAC,KAAK;gBACb,OAAO,EAAE;oBACP,GAAG,OAAO;oBACV,CAAC,GAAG,CAAC,EAAE,OAAO,CAAC,OAAO,CAAC;iBACxB;aACF,CAAA;QACH,CAAC;aAAM,CAAC;YACN,IAAI,CAAC,KAAK,GAAG;gBACX,GAAG,IAAI,CAAC,KAAK;gBACb,CAAC,GAAG,CAAC,EAAE,OAAO,CAAC,OAAO,CAAC;aACxB,CAAA;QACH,CAAC;QAED,IAAI,EAAE,MAAM,EAAE,GAAG,IAAI,CAAC,KAAK,CAAA;QAC3B,IAAI,MAAM,KAAK,MAAM,IAAI,CAAC,CAAA,MAAM,aAAN,MAAM,uBAAN,MAAM,CAAE,QAAQ,CAAC,OAAO,CAAC,CAAA,EAAE,CAAC;YACpD,0BAA0B;YAC1B,OAAO,IAAI,CAAC,KAAK,CAAC,OAAO,CAAA;QAC3B,CAAC;QAED,IAAI,CAAC,aAAa,CAAC,IAAI,WAAW,CAAC,QAAQ,EAAE,EAAE,OAAO,EAAE,IAAI,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC,CAAC,CAAA;IAClF,CAAC;;AA5EM,uBAAM,GAAG,CAAC,kBAAkB,CAAC,AAAvB,CAAuB;AAER;IAA3B,QAAQ,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,CAAC;+CAAmB;AAClB;IAA3B,QAAQ,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,CAAC;+CAAc;AAEhC;IAAR,KAAK,EAAE;oDAA0D","sourcesContent":["/**\n * @license Copyright © HatioLab Inc. All rights reserved.\n */\n\nimport '@operato/input/ox-input-data.js'\nimport '@operato/i18n/ox-i18n.js'\n\nimport { html, LitElement } from 'lit'\nimport { property, state } from 'lit/decorators.js'\n\nimport { Properties, Scene } from '@hatiolab/things-scene'\n\nimport { EffectsSharedStyle } from './effects-shared-style'\nimport { convert } from './value-converter'\n\nexport class PropertyEventTap extends LitElement {\n static styles = [EffectsSharedStyle]\n\n @property({ type: Object }) value?: Properties\n @property({ type: Object }) scene?: Scene\n\n @state() targetList: { value: string; description: string }[] = []\n\n async firstUpdated() {\n this.renderRoot.addEventListener('change', this._onValueChange.bind(this))\n }\n\n render() {\n var { action, target = '', pressed } = this.value || {}\n\n return html`\n <input id=\"checkbox-pressed\" type=\"checkbox\" value-key=\"pressed\" .checked=${pressed} />\n <label for=\"checkbox-pressed\" class=\"checkbox-label\"> <ox-i18n msgid=\"label.pressed\">pressed</ox-i18n> </label>\n\n <label> <ox-i18n msgid=\"label.action\">action</ox-i18n> </label>\n <select id=\"tap-select\" value-key=\"action\" .value=${action || ''}>\n <option value=\"\"></option>\n <option value=\"link-open\">open new window for target link</option>\n <option value=\"link-move\">move to target link</option>\n <option value=\"data-toggle\">toggle data</option>\n <option value=\"legend-toggle\">toggle legend</option>\n <option value=\"popup\">popup target board</option>\n <option value=\"modal-popup\">modal popup target board</option>\n </select>\n\n <label> <ox-i18n msgid=\"label.target\">target</ox-i18n> </label>\n <input value-key=\"target\" .value=${target} .placeholder=${this._getPlaceHoder(action)} />\n `\n }\n\n _getPlaceHoder(action: string) {\n switch (action) {\n case 'link-open':\n case 'link-move':\n return 'http://www.hatiolab.com/'\n default:\n return ''\n }\n }\n\n _onValueChange(e: Event) {\n var element = e.target as HTMLElement\n var key = element.getAttribute('value-key')\n\n if (!key) {\n return\n }\n\n if (key === 'input' || key === 'output') {\n var { options = {} } = this.value || {}\n\n this.value = {\n ...this.value,\n options: {\n ...options,\n [key]: convert(element)\n }\n }\n } else {\n this.value = {\n ...this.value,\n [key]: convert(element)\n }\n }\n\n var { action } = this.value\n if (action !== 'goto' && !action?.includes('popup')) {\n /* clear unused options */\n delete this.value.options\n }\n\n this.dispatchEvent(new CustomEvent('change', { bubbles: true, composed: true }))\n }\n}\n"]}
1
+ {"version":3,"file":"property-event-tap.js","sourceRoot":"","sources":["../../../../../src/modeller/property-sidebar/effects/property-event-tap.ts"],"names":[],"mappings":"AAAA;;GAEG;;AAEH,OAAO,iCAAiC,CAAA;AACxC,OAAO,0BAA0B,CAAA;AAEjC,OAAO,EAAE,IAAI,EAAE,UAAU,EAAE,MAAM,KAAK,CAAA;AACtC,OAAO,EAAE,QAAQ,EAAE,KAAK,EAAE,MAAM,mBAAmB,CAAA;AAInD,OAAO,EAAE,kBAAkB,EAAE,MAAM,wBAAwB,CAAA;AAC3D,OAAO,EAAE,OAAO,EAAE,MAAM,mBAAmB,CAAA;AAE3C,MAAM,OAAO,gBAAiB,SAAQ,UAAU;IAAhD;;QAMW,eAAU,GAA6C,EAAE,CAAA;IAsEpE,CAAC;IApEC,KAAK,CAAC,YAAY;QAChB,IAAI,CAAC,UAAU,CAAC,gBAAgB,CAAC,QAAQ,EAAE,IAAI,CAAC,cAAc,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC,CAAA;IAC5E,CAAC;IAED,MAAM;QACJ,IAAI,EAAE,MAAM,EAAE,MAAM,GAAG,EAAE,EAAE,OAAO,EAAE,GAAG,IAAI,CAAC,KAAK,IAAI,EAAE,CAAA;QAEvD,OAAO,IAAI,CAAA;kFACmE,OAAO;;;;0DAI/B,MAAM,IAAI,EAAE;;;;;;;;;yCAS7B,MAAM,iBAAiB,IAAI,CAAC,cAAc,CAAC,MAAM,CAAC;KACtF,CAAA;IACH,CAAC;IAED,cAAc,CAAC,MAAc;QAC3B,QAAQ,MAAM,EAAE,CAAC;YACf,KAAK,WAAW,CAAC;YACjB,KAAK,WAAW;gBACd,OAAO,0BAA0B,CAAA;YACnC;gBACE,OAAO,EAAE,CAAA;QACb,CAAC;IACH,CAAC;IAED,cAAc,CAAC,CAAQ;QACrB,IAAI,OAAO,GAAG,CAAC,CAAC,MAAqB,CAAA;QACrC,IAAI,GAAG,G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ent":["/**\n * @license Copyright © HatioLab Inc. All rights reserved.\n */\n\nimport '@operato/input/ox-input-data.js'\nimport '@operato/i18n/ox-i18n.js'\n\nimport { html, LitElement } from 'lit'\nimport { property, state } from 'lit/decorators.js'\n\nimport { Properties, Scene } from '@hatiolab/things-scene'\n\nimport { EffectsSharedStyle } from './effects-shared-style'\nimport { convert } from './value-converter'\n\nexport class PropertyEventTap extends LitElement {\n static styles = [EffectsSharedStyle]\n\n @property({ type: Object }) value?: Properties\n @property({ type: Object }) scene?: Scene\n\n @state() targetList: { value: string; description: string }[] = []\n\n async firstUpdated() {\n this.renderRoot.addEventListener('change', this._onValueChange.bind(this))\n }\n\n render() {\n var { action, target = '', pressed } = this.value || {}\n\n return html`\n <input id=\"checkbox-pressed\" type=\"checkbox\" value-key=\"pressed\" .checked=${pressed} />\n <label for=\"checkbox-pressed\" class=\"checkbox-label\"> <ox-i18n msgid=\"label.pressed\">pressed</ox-i18n> </label>\n\n <label> <ox-i18n msgid=\"label.action\">action</ox-i18n> </label>\n <select id=\"tap-select\" value-key=\"action\" .value=${action || ''}>\n <option value=\"\"></option>\n <option value=\"link-open\">open new window for target link</option>\n <option value=\"link-move\">move to target link</option>\n <option value=\"data-toggle\">toggle data</option>\n <option value=\"legend-toggle\">toggle legend</option>\n </select>\n\n <label> <ox-i18n msgid=\"label.target\">target</ox-i18n> </label>\n <input value-key=\"target\" .value=${target} .placeholder=${this._getPlaceHoder(action)} />\n `\n }\n\n _getPlaceHoder(action: string) {\n switch (action) {\n case 'link-open':\n case 'link-move':\n return 'http://www.hatiolab.com/'\n default:\n return ''\n }\n }\n\n _onValueChange(e: Event) {\n var element = e.target as HTMLElement\n var key = element.getAttribute('value-key')\n\n if (!key) {\n return\n }\n\n if (key === 'input' || key === 'output') {\n var { options = {} } = this.value || {}\n\n this.value = {\n ...this.value,\n options: {\n ...options,\n [key]: convert(element)\n }\n }\n } else {\n this.value = {\n ...this.value,\n [key]: convert(element)\n }\n }\n\n var { action } = this.value\n if (action !== 'goto' && !action?.includes('popup')) {\n /* clear unused options */\n delete this.value.options\n }\n\n this.dispatchEvent(new CustomEvent('change', { bubbles: true, composed: true }))\n }\n}\n"]}
@@ -38,6 +38,10 @@ export declare class BoardViewer extends LitElement {
38
38
  fmbMonitoringInitHandler: (e: Event) => void;
39
39
  fmbShowLegendHandler: (e: Event) => void;
40
40
  fmbHideLegendHandler: (e: Event) => void;
41
+ fmbShowPopupHandler: (e: Event) => void;
42
+ fmbHidePopupHandler: (e: Event) => void;
43
+ fmbShowFloatingContainerHandler: (e: Event) => void;
44
+ fmbHideFloatingContainerHandler: (e: Event) => void;
41
45
  clickComponentHandler: (e: Event) => void;
42
46
  fmbStartAnimation: (e: Event) => void;
43
47
  fmbStopAnimation: (e: Event) => void;
@@ -70,6 +70,42 @@ let BoardViewer = class BoardViewer extends LitElement {
70
70
  }
71
71
  legendLayer.hidden = true;
72
72
  };
73
+ // 모니터링에서 팝업을 보여준다.
74
+ this.fmbShowPopupHandler = (e) => {
75
+ var _a;
76
+ const { id, data } = e.detail;
77
+ const popupComponent = (_a = this._scene) === null || _a === void 0 ? void 0 : _a.findById(id);
78
+ if (popupComponent && popupComponent.getState('type') == 'popup') {
79
+ ;
80
+ popupComponent.openPopup(data);
81
+ }
82
+ };
83
+ this.fmbHidePopupHandler = (e) => {
84
+ var _a;
85
+ const { id } = e.detail;
86
+ const popupComponent = (_a = this._scene) === null || _a === void 0 ? void 0 : _a.findById(id);
87
+ if (popupComponent && popupComponent.getState('type') == 'popup') {
88
+ ;
89
+ popupComponent.hidePopup();
90
+ }
91
+ };
92
+ // 모니터링에서 범례를 보여준다.
93
+ this.fmbShowFloatingContainerHandler = (e) => {
94
+ var _a;
95
+ const { id } = e.detail;
96
+ const floatingContainer = (_a = this._scene) === null || _a === void 0 ? void 0 : _a.findById(id);
97
+ if (floatingContainer && floatingContainer.getState('type') == 'floating-container') {
98
+ floatingContainer.hidden = false;
99
+ }
100
+ };
101
+ this.fmbHideFloatingContainerHandler = (e) => {
102
+ var _a;
103
+ const { id } = e.detail;
104
+ const floatingContainer = (_a = this._scene) === null || _a === void 0 ? void 0 : _a.findById(id);
105
+ if (floatingContainer && floatingContainer.getState('type') == 'floating-container') {
106
+ floatingContainer.hidden = true;
107
+ }
108
+ };
73
109
  // BoardComponentInfo popup을 보여준다.
74
110
  this.clickComponentHandler = (e) => {
75
111
  var _a, _b;
@@ -211,6 +247,9 @@ let BoardViewer = class BoardViewer extends LitElement {
211
247
  // 모니터링에서 범례를 보여준다.
212
248
  window.addEventListener('fmbShowLegend', this.fmbShowLegendHandler);
213
249
  window.addEventListener('fmbHideLegend', this.fmbHideLegendHandler);
250
+ // 모니터링에서 범례를 보여준다.
251
+ window.addEventListener('fmbShowPopup', this.fmbShowPopupHandler);
252
+ window.addEventListener('fmbHidePopup', this.fmbHidePopupHandler);
214
253
  }
215
254
  disconnectedCallback() {
216
255
  super.disconnectedCallback();