@gravitee/ui-components 3.25.3-typescript-8a53edf → 3.25.3-typescript-e7256ca

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 (370) hide show
  1. package/package.json +3 -4
  2. package/src/atoms/gv-autocomplete.d.ts +104 -0
  3. package/src/atoms/gv-autocomplete.js +1 -461
  4. package/src/atoms/gv-button.d.ts +109 -0
  5. package/src/atoms/gv-button.js +1 -410
  6. package/src/atoms/gv-checkbox.d.ts +114 -0
  7. package/src/atoms/gv-checkbox.js +1 -187
  8. package/src/atoms/gv-date-picker-calendar.d.ts +190 -0
  9. package/src/atoms/gv-date-picker-calendar.js +1 -894
  10. package/src/atoms/gv-date-picker-cell.d.ts +80 -0
  11. package/src/atoms/gv-date-picker-cell.js +1 -190
  12. package/src/atoms/gv-date-picker.d.ts +194 -0
  13. package/src/atoms/gv-date-picker.js +1 -671
  14. package/src/atoms/gv-file-upload.d.ts +64 -0
  15. package/src/atoms/gv-file-upload.js +1 -367
  16. package/src/atoms/gv-icon.d.ts +26 -0
  17. package/src/atoms/gv-icon.js +1 -103
  18. package/src/atoms/gv-image.d.ts +45 -0
  19. package/src/atoms/gv-image.js +1 -144
  20. package/src/atoms/gv-input-message.d.ts +20 -0
  21. package/src/atoms/gv-input-message.js +1 -84
  22. package/src/atoms/gv-input.d.ts +246 -0
  23. package/src/atoms/gv-input.js +1 -561
  24. package/src/atoms/gv-link.d.ts +67 -0
  25. package/src/atoms/gv-link.js +1 -210
  26. package/src/atoms/gv-message.d.ts +23 -0
  27. package/src/atoms/gv-message.js +1 -128
  28. package/src/atoms/gv-metric.d.ts +32 -0
  29. package/src/atoms/gv-metric.js +1 -117
  30. package/src/atoms/gv-relative-time.d.ts +45 -0
  31. package/src/atoms/gv-relative-time.js +1 -156
  32. package/src/atoms/gv-select-native.d.ts +174 -0
  33. package/src/atoms/gv-select-native.js +1 -388
  34. package/src/atoms/gv-select.d.ts +71 -0
  35. package/src/atoms/gv-select.js +1 -437
  36. package/src/atoms/gv-spinner.d.ts +10 -0
  37. package/src/atoms/gv-spinner.js +1 -57
  38. package/src/atoms/gv-state.d.ts +50 -0
  39. package/src/atoms/gv-state.js +1 -130
  40. package/src/atoms/gv-switch.d.ts +60 -0
  41. package/src/atoms/gv-switch.js +1 -243
  42. package/src/atoms/gv-tag.d.ts +69 -0
  43. package/src/atoms/gv-tag.js +1 -168
  44. package/src/atoms/gv-text.d.ts +110 -0
  45. package/src/atoms/gv-text.js +1 -168
  46. package/src/charts/gv-chart-bar.d.ts +50 -0
  47. package/src/charts/gv-chart-bar.js +1 -103
  48. package/src/charts/gv-chart-gauge.d.ts +58 -0
  49. package/src/charts/gv-chart-gauge.js +1 -100
  50. package/src/charts/gv-chart-histogram.d.ts +48 -0
  51. package/src/charts/gv-chart-histogram.js +1 -83
  52. package/src/charts/gv-chart-line.d.ts +52 -0
  53. package/src/charts/gv-chart-line.js +1 -224
  54. package/src/charts/gv-chart-map.d.ts +50 -0
  55. package/src/charts/gv-chart-map.js +1 -112
  56. package/src/charts/gv-chart-pie.d.ts +50 -0
  57. package/src/charts/gv-chart-pie.js +1 -91
  58. package/src/index.d.ts +77 -0
  59. package/src/index.js +1 -77
  60. package/src/lib/cron-expression.d.ts +1 -0
  61. package/src/lib/cron-expression.js +1 -205
  62. package/src/lib/date.d.ts +1 -0
  63. package/src/lib/date.js +1 -44
  64. package/src/lib/events.d.ts +1 -0
  65. package/src/lib/events.js +1 -26
  66. package/src/lib/http-client-schema-form.d.ts +68 -0
  67. package/src/lib/http-client-schema-form.js +1 -67
  68. package/src/lib/http.d.ts +222 -0
  69. package/src/lib/http.js +1 -237
  70. package/src/lib/i18n.d.ts +30 -0
  71. package/src/lib/i18n.js +1 -103
  72. package/src/lib/item.d.ts +12 -0
  73. package/src/lib/item.js +1 -118
  74. package/src/lib/properties.d.ts +42 -0
  75. package/src/lib/properties.js +1 -189
  76. package/src/lib/schema-form.d.ts +5 -0
  77. package/src/lib/schema-form.js +1 -44
  78. package/src/lib/studio.d.ts +2 -0
  79. package/src/lib/studio.js +1 -141
  80. package/src/lib/style.d.ts +6 -0
  81. package/src/lib/style.js +1 -41
  82. package/src/lib/text-format.d.ts +6 -0
  83. package/src/lib/text-format.js +1 -69
  84. package/src/lib/theme.d.ts +4 -0
  85. package/src/lib/theme.js +1 -63
  86. package/src/lib/utils.d.ts +9 -0
  87. package/src/lib/utils.js +1 -111
  88. package/src/mixins/chart-element.d.ts +39 -0
  89. package/src/mixins/chart-element.js +1 -165
  90. package/src/mixins/input-element.d.ts +64 -0
  91. package/src/mixins/input-element.js +1 -144
  92. package/src/mixins/item-resource.d.ts +56 -0
  93. package/src/mixins/item-resource.js +1 -120
  94. package/src/mixins/keyboard-element.d.ts +25 -0
  95. package/src/mixins/keyboard-element.js +1 -69
  96. package/src/mixins/update-after-browser.d.ts +11 -0
  97. package/src/mixins/update-after-browser.js +1 -30
  98. package/src/mixins/with-resize-observer.d.ts +12 -0
  99. package/src/mixins/with-resize-observer.js +1 -68
  100. package/src/mixins/with-skeleton-attribute.d.ts +35 -0
  101. package/src/mixins/with-skeleton-attribute.js +1 -112
  102. package/src/molecules/gv-card-full.d.ts +78 -0
  103. package/src/molecules/gv-card-full.js +1 -218
  104. package/src/molecules/gv-card-list.d.ts +33 -0
  105. package/src/molecules/gv-card-list.js +1 -113
  106. package/src/molecules/gv-card.d.ts +65 -0
  107. package/src/molecules/gv-card.js +1 -133
  108. package/src/molecules/gv-category-list.d.ts +17 -0
  109. package/src/molecules/gv-category-list.js +1 -60
  110. package/src/molecules/gv-category.d.ts +64 -0
  111. package/src/molecules/gv-category.js +1 -170
  112. package/src/molecules/gv-code.d.ts +192 -0
  113. package/src/molecules/gv-code.js +1 -359
  114. package/src/molecules/gv-confirm.d.ts +60 -0
  115. package/src/molecules/gv-confirm.js +1 -188
  116. package/src/molecules/gv-cron-editor.d.ts +115 -0
  117. package/src/molecules/gv-cron-editor.js +1 -710
  118. package/src/molecules/gv-dropdown-menu.d.ts +28 -0
  119. package/src/molecules/gv-dropdown-menu.js +1 -116
  120. package/src/molecules/gv-expandable.d.ts +37 -0
  121. package/src/molecules/gv-expandable.js +1 -122
  122. package/src/molecules/gv-expression-language.d.ts +150 -0
  123. package/src/molecules/gv-expression-language.js +1 -270
  124. package/src/molecules/gv-identity-picture.d.ts +44 -0
  125. package/src/molecules/gv-identity-picture.js +1 -148
  126. package/src/molecules/gv-list.d.ts +123 -0
  127. package/src/molecules/gv-list.js +1 -227
  128. package/src/molecules/gv-metrics.d.ts +65 -0
  129. package/src/molecules/gv-metrics.js +1 -162
  130. package/src/molecules/gv-modal.d.ts +64 -0
  131. package/src/molecules/gv-modal.js +1 -213
  132. package/src/molecules/gv-nav.d.ts +41 -0
  133. package/src/molecules/gv-nav.js +1 -196
  134. package/src/molecules/gv-option.d.ts +65 -0
  135. package/src/molecules/gv-option.js +1 -242
  136. package/src/molecules/gv-plans.d.ts +73 -0
  137. package/src/molecules/gv-plans.js +1 -429
  138. package/src/molecules/gv-popover.d.ts +91 -0
  139. package/src/molecules/gv-popover.js +1 -351
  140. package/src/molecules/gv-promote.d.ts +108 -0
  141. package/src/molecules/gv-promote.js +1 -209
  142. package/src/molecules/gv-rating-list.d.ts +77 -0
  143. package/src/molecules/gv-rating-list.js +1 -365
  144. package/src/molecules/gv-rating.d.ts +55 -0
  145. package/src/molecules/gv-rating.js +1 -253
  146. package/src/molecules/gv-row-expandable.d.ts +8 -0
  147. package/src/molecules/gv-row-expandable.js +1 -45
  148. package/src/molecules/gv-row.d.ts +37 -0
  149. package/src/molecules/gv-row.js +1 -210
  150. package/src/molecules/gv-stats.d.ts +53 -0
  151. package/src/molecules/gv-stats.js +1 -121
  152. package/src/molecules/gv-stepper.d.ts +46 -0
  153. package/src/molecules/gv-stepper.js +1 -288
  154. package/src/molecules/gv-table.d.ts +159 -0
  155. package/src/molecules/gv-table.js +1 -685
  156. package/src/molecules/gv-tree.d.ts +44 -0
  157. package/src/molecules/gv-tree.js +1 -250
  158. package/src/organisms/gv-documentation.d.ts +52 -0
  159. package/src/organisms/gv-documentation.js +1 -215
  160. package/src/organisms/gv-header.d.ts +60 -0
  161. package/src/organisms/gv-header.js +1 -288
  162. package/src/organisms/gv-http-client.d.ts +57 -0
  163. package/src/organisms/gv-http-client.js +1 -275
  164. package/src/organisms/gv-menu.d.ts +74 -0
  165. package/src/organisms/gv-menu.js +1 -263
  166. package/src/organisms/gv-newsletter-subscription.d.ts +82 -0
  167. package/src/organisms/gv-newsletter-subscription.js +1 -271
  168. package/src/organisms/gv-pagination.d.ts +63 -0
  169. package/src/organisms/gv-pagination.js +1 -198
  170. package/src/organisms/gv-properties.d.ts +229 -0
  171. package/src/organisms/gv-properties.js +1 -920
  172. package/src/organisms/gv-resizable-views.d.ts +33 -0
  173. package/src/organisms/gv-resizable-views.js +1 -396
  174. package/src/organisms/gv-resources.d.ts +125 -0
  175. package/src/organisms/gv-resources.js +1 -535
  176. package/src/organisms/gv-schema-form-array.d.ts +55 -0
  177. package/src/organisms/gv-schema-form-array.js +1 -250
  178. package/src/organisms/gv-schema-form-control-object.d.ts +64 -0
  179. package/src/organisms/gv-schema-form-control-object.js +1 -154
  180. package/src/organisms/gv-schema-form-control.d.ts +90 -0
  181. package/src/organisms/gv-schema-form-control.js +1 -443
  182. package/src/organisms/gv-schema-form.d.ts +156 -0
  183. package/src/organisms/gv-schema-form.js +1 -751
  184. package/src/organisms/gv-tabs.d.ts +56 -0
  185. package/src/organisms/gv-tabs.js +1 -210
  186. package/src/organisms/gv-user-menu.d.ts +56 -0
  187. package/src/organisms/gv-user-menu.js +1 -314
  188. package/src/organisms/gv-vertical-menu.d.ts +28 -0
  189. package/src/organisms/gv-vertical-menu.js +1 -123
  190. package/src/policy-studio/gv-flow-step.d.ts +142 -0
  191. package/src/policy-studio/gv-flow-step.js +1 -464
  192. package/src/policy-studio/gv-flow.d.ts +89 -0
  193. package/src/policy-studio/gv-flow.js +1 -621
  194. package/src/policy-studio/gv-policy-studio-menu.d.ts +94 -0
  195. package/src/policy-studio/gv-policy-studio-menu.js +1 -750
  196. package/src/policy-studio/gv-policy-studio.d.ts +464 -0
  197. package/src/policy-studio/gv-policy-studio.js +1 -1842
  198. package/src/styles/empty.d.ts +1 -0
  199. package/src/styles/empty.js +1 -36
  200. package/src/styles/input.d.ts +1 -0
  201. package/src/styles/input.js +1 -263
  202. package/src/styles/link.d.ts +1 -0
  203. package/src/styles/link.js +1 -32
  204. package/src/styles/shapes.d.ts +2 -0
  205. package/src/styles/shapes.js +1 -17
  206. package/src/styles/skeleton.d.ts +1 -0
  207. package/src/styles/skeleton.js +1 -53
  208. package/src/styles/zoom.d.ts +1 -0
  209. package/src/styles/zoom.js +1 -40
  210. package/src/theme/gv-theme.d.ts +81 -0
  211. package/src/theme/gv-theme.js +1 -203
  212. package/wc/gv-autocomplete.d.ts +1 -0
  213. package/wc/gv-autocomplete.js +1 -1
  214. package/wc/gv-button.d.ts +1 -0
  215. package/wc/gv-button.js +1 -1
  216. package/wc/gv-card-full.d.ts +1 -0
  217. package/wc/gv-card-full.js +1 -1
  218. package/wc/gv-card-list.d.ts +1 -0
  219. package/wc/gv-card-list.js +1 -1
  220. package/wc/gv-card.d.ts +1 -0
  221. package/wc/gv-card.js +1 -1
  222. package/wc/gv-category-list.d.ts +1 -0
  223. package/wc/gv-category-list.js +1 -1
  224. package/wc/gv-category.d.ts +1 -0
  225. package/wc/gv-category.js +1 -1
  226. package/wc/gv-chart-bar.d.ts +1 -0
  227. package/wc/gv-chart-bar.js +1 -1
  228. package/wc/gv-chart-gauge.d.ts +1 -0
  229. package/wc/gv-chart-gauge.js +1 -1
  230. package/wc/gv-chart-histogram.d.ts +1 -0
  231. package/wc/gv-chart-histogram.js +1 -1
  232. package/wc/gv-chart-line.d.ts +1 -0
  233. package/wc/gv-chart-line.js +1 -1
  234. package/wc/gv-chart-map.d.ts +1 -0
  235. package/wc/gv-chart-map.js +1 -1
  236. package/wc/gv-chart-pie.d.ts +1 -0
  237. package/wc/gv-chart-pie.js +1 -1
  238. package/wc/gv-checkbox.d.ts +1 -0
  239. package/wc/gv-checkbox.js +1 -1
  240. package/wc/gv-code.d.ts +1 -0
  241. package/wc/gv-code.js +1 -1
  242. package/wc/gv-confirm.d.ts +1 -0
  243. package/wc/gv-confirm.js +1 -1
  244. package/wc/gv-cron-editor.d.ts +1 -0
  245. package/wc/gv-cron-editor.js +1 -1
  246. package/wc/gv-date-picker-calendar.d.ts +1 -0
  247. package/wc/gv-date-picker-calendar.js +1 -1
  248. package/wc/gv-date-picker-cell.d.ts +1 -0
  249. package/wc/gv-date-picker-cell.js +1 -1
  250. package/wc/gv-date-picker.d.ts +1 -0
  251. package/wc/gv-date-picker.js +1 -1
  252. package/wc/gv-documentation.d.ts +1 -0
  253. package/wc/gv-documentation.js +1 -1
  254. package/wc/gv-dropdown-menu.d.ts +1 -0
  255. package/wc/gv-dropdown-menu.js +1 -1
  256. package/wc/gv-expandable.d.ts +1 -0
  257. package/wc/gv-expandable.js +1 -1
  258. package/wc/gv-expression-language.d.ts +1 -0
  259. package/wc/gv-expression-language.js +1 -1
  260. package/wc/gv-file-upload.d.ts +1 -0
  261. package/wc/gv-file-upload.js +1 -1
  262. package/wc/gv-flow-step.d.ts +1 -0
  263. package/wc/gv-flow-step.js +1 -1
  264. package/wc/gv-flow.d.ts +1 -0
  265. package/wc/gv-flow.js +1 -1
  266. package/wc/gv-header.d.ts +1 -0
  267. package/wc/gv-header.js +1 -1
  268. package/wc/gv-http-client.d.ts +1 -0
  269. package/wc/gv-http-client.js +1 -1
  270. package/wc/gv-icon.d.ts +1 -0
  271. package/wc/gv-icon.js +1 -1
  272. package/wc/gv-identity-picture.d.ts +1 -0
  273. package/wc/gv-identity-picture.js +1 -1
  274. package/wc/gv-image.d.ts +1 -0
  275. package/wc/gv-image.js +1 -1
  276. package/wc/gv-input-message.d.ts +1 -0
  277. package/wc/gv-input-message.js +1 -1
  278. package/wc/gv-input.d.ts +1 -0
  279. package/wc/gv-input.js +1 -1
  280. package/wc/gv-link.d.ts +1 -0
  281. package/wc/gv-link.js +1 -1
  282. package/wc/gv-list.d.ts +1 -0
  283. package/wc/gv-list.js +1 -1
  284. package/wc/gv-menu.d.ts +1 -0
  285. package/wc/gv-menu.js +1 -1
  286. package/wc/gv-message.d.ts +1 -0
  287. package/wc/gv-message.js +1 -1
  288. package/wc/gv-metric.d.ts +1 -0
  289. package/wc/gv-metric.js +1 -1
  290. package/wc/gv-metrics.d.ts +1 -0
  291. package/wc/gv-metrics.js +1 -1
  292. package/wc/gv-modal.d.ts +1 -0
  293. package/wc/gv-modal.js +1 -1
  294. package/wc/gv-nav.d.ts +1 -0
  295. package/wc/gv-nav.js +1 -1
  296. package/wc/gv-newsletter-subscription.d.ts +1 -0
  297. package/wc/gv-newsletter-subscription.js +1 -1
  298. package/wc/gv-option.d.ts +1 -0
  299. package/wc/gv-option.js +1 -1
  300. package/wc/gv-pagination.d.ts +1 -0
  301. package/wc/gv-pagination.js +1 -1
  302. package/wc/gv-plans.d.ts +1 -0
  303. package/wc/gv-plans.js +1 -1
  304. package/wc/gv-policy-studio-menu.d.ts +1 -0
  305. package/wc/gv-policy-studio-menu.js +1 -1
  306. package/wc/gv-policy-studio.d.ts +1 -0
  307. package/wc/gv-policy-studio.js +1 -1
  308. package/wc/gv-popover.d.ts +1 -0
  309. package/wc/gv-popover.js +1 -1
  310. package/wc/gv-promote.d.ts +1 -0
  311. package/wc/gv-promote.js +1 -1
  312. package/wc/gv-properties.d.ts +1 -0
  313. package/wc/gv-properties.js +1 -1
  314. package/wc/gv-rating-list.d.ts +1 -0
  315. package/wc/gv-rating-list.js +1 -1
  316. package/wc/gv-rating.d.ts +1 -0
  317. package/wc/gv-rating.js +1 -1
  318. package/wc/gv-relative-time.d.ts +1 -0
  319. package/wc/gv-relative-time.js +1 -1
  320. package/wc/gv-resizable-views.d.ts +1 -0
  321. package/wc/gv-resizable-views.js +1 -1
  322. package/wc/gv-resources.d.ts +1 -0
  323. package/wc/gv-resources.js +1 -1
  324. package/wc/gv-row-expandable.d.ts +1 -0
  325. package/wc/gv-row-expandable.js +1 -1
  326. package/wc/gv-row.d.ts +1 -0
  327. package/wc/gv-row.js +1 -1
  328. package/wc/gv-schema-form-array.d.ts +1 -0
  329. package/wc/gv-schema-form-array.js +1 -1
  330. package/wc/gv-schema-form-control-object.d.ts +1 -0
  331. package/wc/gv-schema-form-control-object.js +1 -1
  332. package/wc/gv-schema-form-control.d.ts +1 -0
  333. package/wc/gv-schema-form-control.js +1 -1
  334. package/wc/gv-schema-form.d.ts +1 -0
  335. package/wc/gv-schema-form.js +1 -1
  336. package/wc/gv-select-native.d.ts +1 -0
  337. package/wc/gv-select-native.js +1 -1
  338. package/wc/gv-select.d.ts +1 -0
  339. package/wc/gv-select.js +1 -1
  340. package/wc/gv-spinner.d.ts +1 -0
  341. package/wc/gv-spinner.js +1 -1
  342. package/wc/gv-state.d.ts +1 -0
  343. package/wc/gv-state.js +1 -1
  344. package/wc/gv-stats.d.ts +1 -0
  345. package/wc/gv-stats.js +1 -1
  346. package/wc/gv-stepper.d.ts +1 -0
  347. package/wc/gv-stepper.js +1 -1
  348. package/wc/gv-switch.d.ts +1 -0
  349. package/wc/gv-switch.js +1 -1
  350. package/wc/gv-table.d.ts +1 -0
  351. package/wc/gv-table.js +1 -1
  352. package/wc/gv-tabs.d.ts +1 -0
  353. package/wc/gv-tabs.js +1 -1
  354. package/wc/gv-tag.d.ts +1 -0
  355. package/wc/gv-tag.js +1 -1
  356. package/wc/gv-text.d.ts +1 -0
  357. package/wc/gv-text.js +1 -1
  358. package/wc/gv-theme.d.ts +1 -0
  359. package/wc/gv-theme.js +1 -1
  360. package/wc/gv-tree.d.ts +1 -0
  361. package/wc/gv-tree.js +1 -1
  362. package/wc/gv-user-menu.d.ts +1 -0
  363. package/wc/gv-user-menu.js +1 -1
  364. package/wc/gv-vertical-menu.d.ts +1 -0
  365. package/wc/gv-vertical-menu.js +1 -1
  366. package/CHANGELOG.md +0 -1292
  367. package/LICENSE.txt +0 -202
  368. package/README.md +0 -195
  369. package/src/.eslintrc.js +0 -19
  370. package/src/theme/definition.json +0 -1762
@@ -0,0 +1,28 @@
1
+ /**
2
+ * Dropdown menu
3
+ *
4
+ * @slot - The element which must be clicked to open the actions
5
+ * @slot actions - Element that contains actions
6
+ *
7
+ * @attr {Boolean} open - true, if menu should be open
8
+ * @attr {Boolean} right - true, if actions should at right of container when opened
9
+ */
10
+ export class GvDropdownMenu extends LitElement {
11
+ static get properties(): {
12
+ open: {
13
+ type: BooleanConstructor;
14
+ reflect: boolean;
15
+ };
16
+ right: {
17
+ type: BooleanConstructor;
18
+ reflect: boolean;
19
+ };
20
+ };
21
+ static get styles(): import("lit").CSSResult[];
22
+ open: boolean;
23
+ right: boolean;
24
+ _handleDocumentClick: () => void;
25
+ _onDocumentClick(): void;
26
+ toggle(): void;
27
+ }
28
+ import { LitElement } from "lit-element/lit-element";
@@ -1,116 +1 @@
1
- /*
2
- * Copyright (C) 2015 The Gravitee team (http://gravitee.io)
3
- *
4
- * Licensed under the Apache License, Version 2.0 (the "License");
5
- * you may not use this file except in compliance with the License.
6
- * You may obtain a copy of the License at
7
- *
8
- * http://www.apache.org/licenses/LICENSE-2.0
9
- *
10
- * Unless required by applicable law or agreed to in writing, software
11
- * distributed under the License is distributed on an "AS IS" BASIS,
12
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
- * See the License for the specific language governing permissions and
14
- * limitations under the License.
15
- */
16
- import { css, LitElement, html } from 'lit';
17
-
18
- /**
19
- * Dropdown menu
20
- *
21
- * @slot - The element which must be clicked to open the actions
22
- * @slot actions - Element that contains actions
23
- *
24
- * @attr {Boolean} open - true, if menu should be open
25
- * @attr {Boolean} right - true, if actions should at right of container when opened
26
- */
27
- export class GvDropdownMenu extends LitElement {
28
- static get properties() {
29
- return {
30
- open: { type: Boolean, reflect: true },
31
- right: { type: Boolean, reflect: true },
32
- };
33
- }
34
-
35
- static get styles() {
36
- return [
37
- // language=CSS
38
- css`
39
- :host {
40
- box-sizing: border-box;
41
- display: block;
42
- }
43
-
44
- .actions {
45
- position: absolute;
46
- background-color: white;
47
- transition: all 300ms ease-in-out;
48
- border-style: solid;
49
- border-color: #bfbfbf;
50
- border-width: var(--gv-dropdown-menu--bdw, 1px 1px 1px 1px);
51
- z-index: 201;
52
- padding: var(--gv-dropdown-menu--p, 0.5rem);
53
- visibility: hidden;
54
- opacity: 0;
55
- display: grid;
56
- grid-gap: var(--gv-dropdown-menu--gg, 0.2rem);
57
- bottom: 0;
58
- top: 0;
59
- }
60
-
61
- :host([open]) .actions {
62
- opacity: 1;
63
- visibility: visible;
64
- cursor: pointer;
65
- }
66
-
67
- :host([right]) .actions {
68
- right: 0px;
69
- }
70
- `,
71
- ];
72
- }
73
-
74
- constructor() {
75
- super();
76
- this.open = false;
77
- this.right = false;
78
- this._handleDocumentClick = this._onDocumentClick.bind(this);
79
- }
80
-
81
- connectedCallback() {
82
- super.connectedCallback();
83
- }
84
-
85
- disconnectedCallback() {
86
- window.removeEventListener('click', this._handleDocumentClick);
87
- super.disconnectedCallback();
88
- }
89
-
90
- _onDocumentClick() {
91
- this.open = false;
92
- window.removeEventListener('click', this._handleDocumentClick);
93
- }
94
-
95
- toggle() {
96
- this.open = !this.open;
97
- setTimeout(() => {
98
- if (this.open) {
99
- window.addEventListener('click', this._handleDocumentClick);
100
- } else {
101
- window.removeEventListener('click', this._handleDocumentClick);
102
- }
103
- }, 0);
104
- }
105
-
106
- render() {
107
- return html`<div class="box">
108
- <slot @click="${this.toggle}"></slot>
109
- <div class="actions">
110
- <slot name="action" class="action"></slot>
111
- </div>
112
- </div>`;
113
- }
114
- }
115
-
116
- window.customElements.define('gv-dropdown-menu', GvDropdownMenu);
1
+ Object.defineProperty(exports,"__esModule",{value:!0}),exports.GvDropdownMenu=void 0;const e=require("lit");class t extends e.LitElement{static get properties(){return{open:{type:Boolean,reflect:!0},right:{type:Boolean,reflect:!0}}}static get styles(){return[e.css`:host{box-sizing:border-box;display:block}.actions{position:absolute;background-color:#fff;transition:all .3s ease-in-out;border-style:solid;border-color:#bfbfbf;border-width:var(--gv-dropdown-menu--bdw,1px 1px 1px 1px);z-index:201;padding:var(--gv-dropdown-menu--p,.5rem);visibility:hidden;opacity:0;display:grid;grid-gap:var(--gv-dropdown-menu--gg,.2rem);bottom:0;top:0}:host([open]) .actions{opacity:1;visibility:visible;cursor:pointer}:host([right]) .actions{right:0}`]}constructor(){super(),this.open=!1,this.right=!1,this._handleDocumentClick=this._onDocumentClick.bind(this)}connectedCallback(){super.connectedCallback()}disconnectedCallback(){window.removeEventListener("click",this._handleDocumentClick),super.disconnectedCallback()}_onDocumentClick(){this.open=!1,window.removeEventListener("click",this._handleDocumentClick)}toggle(){this.open=!this.open,setTimeout((()=>{this.open?window.addEventListener("click",this._handleDocumentClick):window.removeEventListener("click",this._handleDocumentClick)}),0)}render(){return e.html`<div class="box"><slot @click="${this.toggle}"></slot><div class="actions"><slot name="action" class="action"></slot></div></div>`}}exports.GvDropdownMenu=t,window.customElements.define("gv-dropdown-menu",t);
@@ -0,0 +1,37 @@
1
+ /**
2
+ * Expandable component
3
+ *
4
+ * @fires gv-expandable:toggle - When user toggle
5
+ *
6
+ * @attr {Boolean} open - When true, opens details by default
7
+ * @attr {String} icon - An icon to show open feature
8
+ * @attr {String} icon-opened - An icon to show close feature
9
+ * @attr {Boolean} clickable - When true, details is clickable like summary
10
+ *
11
+ * @cssprop {String} [--gv-expandable--bdb=var(--gv-expandable--bdb, thin solid var(--gv-theme-color, #5a7684)] - Border bottom
12
+ */
13
+ export class GvExpandable extends LitElement {
14
+ static get properties(): {
15
+ open: {
16
+ type: BooleanConstructor;
17
+ reflect: boolean;
18
+ };
19
+ icon: {
20
+ type: StringConstructor;
21
+ };
22
+ iconOpened: {
23
+ type: StringConstructor;
24
+ attribute: string;
25
+ };
26
+ clickable: {
27
+ type: BooleanConstructor;
28
+ };
29
+ };
30
+ static get styles(): import("lit").CSSResult[];
31
+ open: boolean;
32
+ icon: string;
33
+ iconOpened: string;
34
+ clickable: boolean;
35
+ _onClick(event: any): void;
36
+ }
37
+ import { LitElement } from "lit-element/lit-element";
@@ -1,122 +1 @@
1
- /*
2
- * Copyright (C) 2015 The Gravitee team (http://gravitee.io)
3
- *
4
- * Licensed under the Apache License, Version 2.0 (the "License");
5
- * you may not use this file except in compliance with the License.
6
- * You may obtain a copy of the License at
7
- *
8
- * http://www.apache.org/licenses/LICENSE-2.0
9
- *
10
- * Unless required by applicable law or agreed to in writing, software
11
- * distributed under the License is distributed on an "AS IS" BASIS,
12
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
- * See the License for the specific language governing permissions and
14
- * limitations under the License.
15
- */
16
- import { css, html, LitElement } from 'lit';
17
- import { link } from '../styles/link';
18
- import { classMap } from 'lit/directives/class-map';
19
- import { dispatchCustomEvent } from '../lib/events';
20
-
21
- /**
22
- * Expandable component
23
- *
24
- * @fires gv-expandable:toggle - When user toggle
25
- *
26
- * @attr {Boolean} open - When true, opens details by default
27
- * @attr {String} icon - An icon to show open feature
28
- * @attr {String} icon-opened - An icon to show close feature
29
- * @attr {Boolean} clickable - When true, details is clickable like summary
30
- *
31
- * @cssprop {String} [--gv-expandable--bdb=var(--gv-expandable--bdb, thin solid var(--gv-theme-color, #5a7684)] - Border bottom
32
- */
33
- export class GvExpandable extends LitElement {
34
- constructor() {
35
- super();
36
- this.open = false;
37
- this.icon = 'navigation:angle-left';
38
- this.iconOpened = 'navigation:angle-down';
39
- this.clickable = false;
40
- }
41
-
42
- static get properties() {
43
- return {
44
- open: { type: Boolean, reflect: true },
45
- icon: { type: String },
46
- iconOpened: { type: String, attribute: 'icon-opened' },
47
- clickable: { type: Boolean },
48
- };
49
- }
50
-
51
- static get styles() {
52
- return [
53
- link,
54
- // language=CSS
55
- css`
56
- :host {
57
- box-sizing: border-box;
58
- }
59
-
60
- .box {
61
- padding: 0.2rem;
62
- line-height: 23px;
63
- border-bottom: var(--gv-expandable--bdb, thin solid var(--gv-theme-color, #5a7684));
64
- }
65
-
66
- :host([open]) .details {
67
- visibility: visible;
68
- opacity: 1;
69
- height: auto;
70
- overflow: visible;
71
- }
72
-
73
- .details {
74
- display: block;
75
- overflow: hidden;
76
- opacity: 0;
77
- visibility: hidden;
78
- transition: all 150ms ease-in-out;
79
- height: 0;
80
- }
81
-
82
- .summary {
83
- display: flex;
84
- flex-direction: row;
85
- align-content: center;
86
- justify-content: space-between;
87
- }
88
-
89
- .expand {
90
- align-self: center;
91
- margin-left: 5px;
92
- --gv-icon--s: 16px;
93
- }
94
- `,
95
- ];
96
- }
97
-
98
- _onClick(event) {
99
- if (!this.clickable) {
100
- const summary = this.shadowRoot.querySelector('.summary');
101
- if (!summary.contains(event.target) && event.target.slot !== 'summary') {
102
- return;
103
- }
104
- }
105
- this.open = !this.open;
106
- dispatchCustomEvent(this, 'toggle', { open: this.open });
107
- }
108
-
109
- render() {
110
- const icon = this.open ? this.iconOpened : this.icon;
111
- return html`<div class="${classMap({ box: true, link: this.clickable })}" @click=${this._onClick}>
112
- <div class="${classMap({ summary: true, link: !this.clickable })}">
113
- <slot name="summary"></slot>
114
-
115
- <gv-icon shape="${icon}" class="expand"></gv-icon>
116
- </div>
117
- <slot name="details" class="details"></slot>
118
- </div>`;
119
- }
120
- }
121
-
122
- window.customElements.define('gv-expandable', GvExpandable);
1
+ Object.defineProperty(exports,"__esModule",{value:!0}),exports.GvExpandable=void 0;const e=require("lit"),i=require("../styles/link"),t=require("lit/directives/class-map"),s=require("../lib/events");class n extends e.LitElement{constructor(){super(),this.open=!1,this.icon="navigation:angle-left",this.iconOpened="navigation:angle-down",this.clickable=!1}static get properties(){return{open:{type:Boolean,reflect:!0},icon:{type:String},iconOpened:{type:String,attribute:"icon-opened"},clickable:{type:Boolean}}}static get styles(){return[i.link,e.css`:host{box-sizing:border-box}.box{padding:.2rem;line-height:23px;border-bottom:var(--gv-expandable--bdb,thin solid var(--gv-theme-color,#5a7684))}:host([open]) .details{visibility:visible;opacity:1;height:auto;overflow:visible}.details{display:block;overflow:hidden;opacity:0;visibility:hidden;transition:all 150ms ease-in-out;height:0}.summary{display:flex;flex-direction:row;align-content:center;justify-content:space-between}.expand{align-self:center;margin-left:5px;--gv-icon--s:16px}`]}_onClick(e){if(!this.clickable){if(!this.shadowRoot.querySelector(".summary").contains(e.target)&&"summary"!==e.target.slot)return}this.open=!this.open,(0,s.dispatchCustomEvent)(this,"toggle",{open:this.open})}render(){const i=this.open?this.iconOpened:this.icon;return e.html`<div class="${(0,t.classMap)({box:!0,link:this.clickable})}" @click="${this._onClick}"><div class="${(0,t.classMap)({summary:!0,link:!this.clickable})}"><slot name="summary"></slot><gv-icon shape="${i}" class="expand"></gv-icon></div><slot name="details" class="details"></slot></div>`}}exports.GvExpandable=n,window.customElements.define("gv-expandable",n);
@@ -0,0 +1,150 @@
1
+ /**
2
+ * Expression Language component
3
+ *
4
+ * @fires gv-expression-language:input - input events with the `value` on `detail`
5
+ * @fires gv-expression-language:ready - event dispatch when component is ready
6
+ * @fires gv-expression-language:clipboard-copy - event dispatch when component the `value` has been copied to clipboard
7
+ *
8
+ * @attr {String} label - code language
9
+ * @attr {String} value - code content to be highlighted
10
+ * @attr {options} Object - options based on codemirror
11
+ * @attr {String} placeholder - an example value to display in the input when empty
12
+ * @attr {Number} rows - number of rows of the text element
13
+ * @attr {Boolean} large - for a large input (only if the field has one row)
14
+ * @attr {Boolean} medium - for a medium input (only if the field has one row) (Default)
15
+ * @attr {Boolean} small - for a small input (only if the field has one row)
16
+ * @attr {Object} grammar - The grammar for Expression Language support
17
+ *
18
+ * @attr {Boolean} [clipboard=false]- true if field has clipboard button
19
+ * @attr {Boolean} [autofocus=false] - true to put the focus on the input
20
+ * @attr {Boolean} [readonly=false] - true if field is readonly mode
21
+ */
22
+ export class GvExpressionLanguage extends GvCode {
23
+ static get properties(): {
24
+ grammar: {
25
+ type: ObjectConstructor;
26
+ };
27
+ options: {
28
+ type: ObjectConstructor;
29
+ };
30
+ rows: {
31
+ type: NumberConstructor;
32
+ };
33
+ _error: {
34
+ type: StringConstructor;
35
+ attribute: boolean;
36
+ };
37
+ type: {
38
+ type: StringConstructor;
39
+ reflect: boolean;
40
+ };
41
+ large: {
42
+ type: BooleanConstructor;
43
+ };
44
+ medium: {
45
+ type: BooleanConstructor;
46
+ };
47
+ small: {
48
+ type: BooleanConstructor;
49
+ };
50
+ icon: {
51
+ type: StringConstructor;
52
+ };
53
+ iconLeft: {
54
+ type: StringConstructor;
55
+ attribute: string;
56
+ };
57
+ loading: {
58
+ type: BooleanConstructor;
59
+ };
60
+ min: {
61
+ type: NumberConstructor;
62
+ };
63
+ max: {
64
+ type: NumberConstructor;
65
+ };
66
+ autocomplete: {
67
+ type: StringConstructor;
68
+ };
69
+ clipboard: {
70
+ type: BooleanConstructor;
71
+ };
72
+ clickable: {
73
+ type: BooleanConstructor;
74
+ };
75
+ clearable: {
76
+ type: BooleanConstructor;
77
+ };
78
+ noSubmit: {
79
+ type: BooleanConstructor;
80
+ attribute: string;
81
+ };
82
+ pattern: {
83
+ type: StringConstructor;
84
+ reflect: boolean;
85
+ };
86
+ description: {
87
+ type: StringConstructor;
88
+ };
89
+ _type: {
90
+ type: StringConstructor;
91
+ attribute: boolean;
92
+ };
93
+ disabled: {
94
+ type: BooleanConstructor;
95
+ reflect: boolean;
96
+ };
97
+ required: {
98
+ type: BooleanConstructor;
99
+ reflect: boolean;
100
+ };
101
+ readonly: {
102
+ type: BooleanConstructor;
103
+ reflect: boolean;
104
+ };
105
+ skeleton: {
106
+ type: BooleanConstructor;
107
+ };
108
+ value: {
109
+ type: StringConstructor;
110
+ reflect: boolean;
111
+ };
112
+ label: {
113
+ type: StringConstructor;
114
+ };
115
+ title: {
116
+ type: StringConstructor;
117
+ };
118
+ name: {
119
+ type: StringConstructor;
120
+ };
121
+ placeholder: {
122
+ type: StringConstructor;
123
+ };
124
+ autofocus: {
125
+ type: BooleanConstructor;
126
+ };
127
+ invalid: {
128
+ type: BooleanConstructor;
129
+ reflect: boolean;
130
+ };
131
+ valid: {
132
+ type: BooleanConstructor;
133
+ reflect: boolean;
134
+ };
135
+ };
136
+ insertELKeymap(): import("@codemirror/state").Extension;
137
+ buildMethods(type: any): any;
138
+ getModelType(typeId: any): any;
139
+ isMap(typeId: any): boolean;
140
+ getEnum(typeId: any): any;
141
+ convertType(type: any): "text" | "variable" | "type" | "enum";
142
+ get expressionLanguageCompletionHandlers(): ({
143
+ run(completionContext: any): any;
144
+ } | {
145
+ expr: RegExp;
146
+ supportEL: boolean;
147
+ run(completionContext: any, match: any): any;
148
+ })[];
149
+ }
150
+ import { GvCode } from "../molecules/gv-code";