@supersoniks/concorde 3.1.76 → 3.1.78

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 (216) hide show
  1. package/build-infos.json +1 -1
  2. package/concorde-core.bundle.js +2 -2
  3. package/concorde-core.es.js +2 -2
  4. package/dist/concorde-core.bundle.js +2 -2
  5. package/dist/concorde-core.es.js +2 -2
  6. package/docs/assets/index-D9bBwsCn.js +4537 -0
  7. package/docs/assets/index-DCRPZO3x.css +1 -0
  8. package/docs/css/docs.css +0 -0
  9. package/docs/fonts/ClashGrotesk-Bold.eot +0 -0
  10. package/docs/fonts/ClashGrotesk-Bold.ttf +0 -0
  11. package/docs/fonts/ClashGrotesk-Bold.woff +0 -0
  12. package/docs/fonts/ClashGrotesk-Bold.woff2 +0 -0
  13. package/docs/fonts/ClashGrotesk-Extralight.eot +0 -0
  14. package/docs/fonts/ClashGrotesk-Extralight.ttf +0 -0
  15. package/docs/fonts/ClashGrotesk-Extralight.woff +0 -0
  16. package/docs/fonts/ClashGrotesk-Extralight.woff2 +0 -0
  17. package/docs/fonts/ClashGrotesk-Light.eot +0 -0
  18. package/docs/fonts/ClashGrotesk-Light.ttf +0 -0
  19. package/docs/fonts/ClashGrotesk-Light.woff +0 -0
  20. package/docs/fonts/ClashGrotesk-Light.woff2 +0 -0
  21. package/docs/fonts/ClashGrotesk-Medium.eot +0 -0
  22. package/docs/fonts/ClashGrotesk-Medium.ttf +0 -0
  23. package/docs/fonts/ClashGrotesk-Medium.woff +0 -0
  24. package/docs/fonts/ClashGrotesk-Medium.woff2 +0 -0
  25. package/docs/fonts/ClashGrotesk-Regular.eot +0 -0
  26. package/docs/fonts/ClashGrotesk-Regular.ttf +0 -0
  27. package/docs/fonts/ClashGrotesk-Regular.woff +0 -0
  28. package/docs/fonts/ClashGrotesk-Regular.woff2 +0 -0
  29. package/docs/fonts/ClashGrotesk-Semibold.eot +0 -0
  30. package/docs/fonts/ClashGrotesk-Semibold.ttf +0 -0
  31. package/docs/fonts/ClashGrotesk-Semibold.woff +0 -0
  32. package/docs/fonts/ClashGrotesk-Semibold.woff2 +0 -0
  33. package/docs/fonts/ClashGrotesk-Variable.eot +0 -0
  34. package/docs/fonts/ClashGrotesk-Variable.ttf +0 -0
  35. package/docs/fonts/ClashGrotesk-Variable.woff +0 -0
  36. package/docs/fonts/ClashGrotesk-Variable.woff2 +0 -0
  37. package/docs/img/concorde-icon.svg +5 -0
  38. package/docs/img/concorde-logo.svg +1 -0
  39. package/docs/img/concorde.png +0 -0
  40. package/docs/img/concorde_def.png +0 -0
  41. package/docs/img/concorde_seuil.png.webp +0 -0
  42. package/docs/img/concorde_seuil_invert.png +0 -0
  43. package/docs/img/paul_metrand.jpg +0 -0
  44. package/docs/img/paul_metrand_xs.jpg +0 -0
  45. package/docs/index.html +93 -0
  46. package/docs/src/core/components/functional/date/date.md +290 -0
  47. package/docs/src/core/components/functional/fetch/fetch.md +117 -0
  48. package/docs/src/core/components/functional/if/if.md +16 -0
  49. package/docs/src/core/components/functional/list/list.md +199 -0
  50. package/docs/src/core/components/functional/mix/mix.md +41 -0
  51. package/docs/src/core/components/functional/queue/queue.md +87 -0
  52. package/docs/src/core/components/functional/router/router.md +108 -0
  53. package/docs/src/core/components/functional/sdui/default-library.json +108 -0
  54. package/docs/src/core/components/functional/sdui/example.json +99 -0
  55. package/docs/src/core/components/functional/sdui/sdui.md +356 -0
  56. package/docs/src/core/components/functional/states/states.md +87 -0
  57. package/docs/src/core/components/functional/submit/submit.md +83 -0
  58. package/docs/src/core/components/functional/subscriber/subscriber.md +91 -0
  59. package/docs/src/core/components/functional/value/value.md +35 -0
  60. package/docs/src/core/components/ui/alert/alert.md +121 -0
  61. package/docs/src/core/components/ui/alert-messages/alert-messages.md +0 -0
  62. package/docs/src/core/components/ui/badge/badge.md +127 -0
  63. package/docs/src/core/components/ui/button/button.md +182 -0
  64. package/docs/src/core/components/ui/captcha/captcha.md +12 -0
  65. package/docs/src/core/components/ui/card/card.md +97 -0
  66. package/docs/src/core/components/ui/divider/divider.md +35 -0
  67. package/docs/src/core/components/ui/form/checkbox/checkbox.md +94 -0
  68. package/docs/src/core/components/ui/form/fieldset/fieldset.md +129 -0
  69. package/docs/src/core/components/ui/form/form-actions/form-actions.md +77 -0
  70. package/docs/src/core/components/ui/form/form-layout/form-layout.md +44 -0
  71. package/docs/src/core/components/ui/form/input/input.md +167 -0
  72. package/docs/src/core/components/ui/form/input-autocomplete/input-autocomplete.md +130 -0
  73. package/docs/src/core/components/ui/form/radio/radio.md +84 -0
  74. package/docs/src/core/components/ui/form/select/select.md +97 -0
  75. package/docs/src/core/components/ui/form/switch/switch.md +84 -0
  76. package/docs/src/core/components/ui/form/textarea/textarea.md +65 -0
  77. package/docs/src/core/components/ui/group/group.md +75 -0
  78. package/docs/src/core/components/ui/icon/icon.md +125 -0
  79. package/docs/src/core/components/ui/icon/icons.json +1 -0
  80. package/docs/src/core/components/ui/image/image.md +107 -0
  81. package/docs/src/core/components/ui/link/link.md +43 -0
  82. package/docs/src/core/components/ui/loader/loader.md +67 -0
  83. package/docs/src/core/components/ui/menu/menu.md +288 -0
  84. package/docs/src/core/components/ui/modal/modal.md +123 -0
  85. package/docs/src/core/components/ui/pop/pop.md +79 -0
  86. package/docs/src/core/components/ui/progress/progress.md +63 -0
  87. package/docs/src/core/components/ui/table/table.md +455 -0
  88. package/docs/src/core/components/ui/tooltip/tooltip.md +82 -0
  89. package/docs/src/docs/_core-concept/overview.md +57 -0
  90. package/docs/src/docs/_core-concept/subscriber.md +76 -0
  91. package/docs/src/docs/_getting-started/concorde-outside.md +143 -0
  92. package/docs/src/docs/_getting-started/create-a-component.md +137 -0
  93. package/docs/src/docs/_getting-started/my-first-subscriber.md +174 -0
  94. package/docs/src/docs/_getting-started/pubsub.md +150 -0
  95. package/docs/src/docs/_getting-started/start.md +39 -0
  96. package/docs/src/docs/_getting-started/theming.md +91 -0
  97. package/docs/src/docs/search/docs-search.json +3902 -0
  98. package/docs/src/tag-list.json +1 -0
  99. package/docs/src/tsconfig-model.json +23 -0
  100. package/docs/src/tsconfig.json +835 -0
  101. package/docs/svg/regular/plane.svg +1 -0
  102. package/docs/svg/solid/plane.svg +1 -0
  103. package/index.html +0 -0
  104. package/package.json +1 -1
  105. package/php/get-challenge.php +34 -0
  106. package/php/some-service.php +42 -0
  107. package/scripts/create-search.js +0 -0
  108. package/scripts/generate-routes.js +0 -0
  109. package/src/core/_types/types.ts +0 -0
  110. package/src/core/components/functional/date/date.ts +0 -0
  111. package/src/core/components/functional/functional.ts +0 -0
  112. package/src/core/components/functional/if/if.md +0 -0
  113. package/src/core/components/functional/if/if.test.ts +0 -0
  114. package/src/core/components/functional/list/list.demo.ts +0 -0
  115. package/src/core/components/functional/list/list.spec.ts +0 -0
  116. package/src/core/components/functional/queue/queue.demo.ts +0 -0
  117. package/src/core/components/functional/queue/queue.ts +1 -1
  118. package/src/core/components/functional/router/router.demo.ts +0 -0
  119. package/src/core/components/functional/router/router.md +0 -0
  120. package/src/core/components/functional/router/router.spec.ts +0 -0
  121. package/src/core/components/functional/router/router.ts +0 -0
  122. package/src/core/components/functional/sonic-scope/sonic-scope.ts +0 -0
  123. package/src/core/components/functional/states/states.demo.ts +0 -0
  124. package/src/core/components/functional/states/states.md +0 -0
  125. package/src/core/components/functional/states/states.spec.ts +0 -0
  126. package/src/core/components/functional/states/states.ts +0 -0
  127. package/src/core/components/functional/translation/translation.ts +0 -0
  128. package/src/core/components/ui/_css/scroll.ts +0 -0
  129. package/src/core/components/ui/_css/shadow.ts +0 -0
  130. package/src/core/components/ui/_css/size.ts +0 -0
  131. package/src/core/components/ui/_css/type.ts +0 -0
  132. package/src/core/components/ui/alert/alert.md +0 -0
  133. package/src/core/components/ui/alert/alert.ts +0 -0
  134. package/src/core/components/ui/alert-messages/alert-messages.md +0 -0
  135. package/src/core/components/ui/badge/badge.md +0 -0
  136. package/src/core/components/ui/badge/badge.ts +0 -0
  137. package/src/core/components/ui/button/button.md +0 -0
  138. package/src/core/components/ui/button/button.ts +0 -0
  139. package/src/core/components/ui/captcha/captcha.md +0 -0
  140. package/src/core/components/ui/card/card-footer.ts +0 -0
  141. package/src/core/components/ui/card/card-header-descripton.ts +0 -0
  142. package/src/core/components/ui/card/card-header.ts +0 -0
  143. package/src/core/components/ui/card/card-main.ts +0 -0
  144. package/src/core/components/ui/card/card.md +0 -0
  145. package/src/core/components/ui/card/card.ts +0 -0
  146. package/src/core/components/ui/divider/divider.ts +0 -0
  147. package/src/core/components/ui/form/css/form-control.ts +0 -0
  148. package/src/core/components/ui/form/fieldset/fieldset.ts +0 -0
  149. package/src/core/components/ui/form/fieldset/legend-description.ts +0 -0
  150. package/src/core/components/ui/form/fieldset/legend.ts +0 -0
  151. package/src/core/components/ui/form/form-layout/form-layout.md +0 -0
  152. package/src/core/components/ui/form/input/input.md +0 -0
  153. package/src/core/components/ui/form/input-autocomplete/input-autocomplete.ts +0 -0
  154. package/src/core/components/ui/form/radio/radio.md +0 -0
  155. package/src/core/components/ui/form/radio/radio.ts +0 -0
  156. package/src/core/components/ui/form/select/select.md +0 -0
  157. package/src/core/components/ui/form/switch/switch.md +0 -0
  158. package/src/core/components/ui/form/switch/switch.ts +0 -0
  159. package/src/core/components/ui/icon/icon.ts +0 -0
  160. package/src/core/components/ui/icon/icons.ts +1 -1
  161. package/src/core/components/ui/image/image.md +0 -0
  162. package/src/core/components/ui/image/image.ts +0 -0
  163. package/src/core/components/ui/loader/loader.md +0 -0
  164. package/src/core/components/ui/loader/loader.ts +0 -0
  165. package/src/core/components/ui/loader/styles/fixed.ts +0 -0
  166. package/src/core/components/ui/loader/styles/inline.ts +0 -0
  167. package/src/core/components/ui/menu/menu.ts +0 -0
  168. package/src/core/components/ui/modal/modal-actions.ts +0 -0
  169. package/src/core/components/ui/modal/modal-subtitle.ts +0 -0
  170. package/src/core/components/ui/modal/modal-title.ts +0 -0
  171. package/src/core/components/ui/modal/modal.md +0 -0
  172. package/src/core/components/ui/modal/modal.ts +0 -0
  173. package/src/core/components/ui/progress/progress.ts +0 -0
  174. package/src/core/components/ui/table/table-tbody.ts +0 -0
  175. package/src/core/components/ui/table/table-th.ts +0 -0
  176. package/src/core/components/ui/table/table.ts +0 -0
  177. package/src/core/components/ui/theme/theme-collection/core-variables.ts +0 -0
  178. package/src/core/components/ui/theme/theme-collection/dark.ts +0 -0
  179. package/src/core/components/ui/theme/theme-collection/light.ts +0 -0
  180. package/src/core/components/ui/theme/theme.ts +0 -0
  181. package/src/core/components/ui/toast/toast-item.ts +0 -0
  182. package/src/core/components/ui/toast/toast.ts +0 -0
  183. package/src/core/components/ui/tooltip/tooltip.ts +0 -0
  184. package/src/core/components/ui/ui.ts +0 -0
  185. package/src/core/directives/DataProvider.ts +0 -0
  186. package/src/core/directives/Wording.ts +0 -0
  187. package/src/core/mixins/Fetcher.ts +0 -0
  188. package/src/core/mixins/Subscriber.ts +0 -0
  189. package/src/core/mixins/TemplatesContainer.ts +0 -0
  190. package/src/core/utils/LocationHandler.ts +0 -0
  191. package/src/core/utils/Objects.ts +0 -0
  192. package/src/core/utils/Utils.ts +0 -0
  193. package/src/core/utils/aesCrypto.ts +0 -0
  194. package/src/core/utils/api.ts +0 -0
  195. package/src/core/utils/route.spec.ts +0 -0
  196. package/src/core/utils/route.ts +0 -0
  197. package/src/docs/code.ts +0 -0
  198. package/src/docs/docs.ts +0 -0
  199. package/src/docs/header/header.ts +0 -0
  200. package/src/docs/layout.ts +0 -0
  201. package/src/docs/navigation/navigation.ts +0 -0
  202. package/src/docs/search/docs-search.json +0 -0
  203. package/src/docs/search/markdown-renderer.ts +0 -0
  204. package/src/docs/search/page.ts +0 -0
  205. package/src/docs/search/search.ts +0 -0
  206. package/src/docs/tailwind/css/tailwind.css +0 -0
  207. package/src/docs/tailwind/css.d.ts +0 -0
  208. package/src/index.ts +0 -0
  209. package/src/test-utils/TestUtils.ts +0 -0
  210. package/src/tsconfig-model.json +0 -0
  211. package/src/tsconfig.json +0 -0
  212. package/src/tsconfig.tsbuildinfo +0 -0
  213. package/tailwind.config.js +0 -0
  214. package/templates-test.html +0 -0
  215. package/vite/config.js +0 -0
  216. package/vite.config.mts +0 -0
@@ -0,0 +1,130 @@
1
+ # Input-autocomplete
2
+
3
+ The input-autocomplete component brings input and queue together in order to create a suggest behavior. This is why this component is partially configured as a form [input](#core/components/ui/form/input/input.md/input) and as a [queue](#core/components/functional/queue/queue.md/queue).
4
+
5
+ Please note that only basic text input params and methods are implemented at this time. You should also be sure to understand the behavior of a [queue](#core/components/functional/queue/queue.md/queue) in order to take full advantage of the input-autocomplete component.
6
+
7
+ Here are some of the features of the input-autocomplete component:
8
+
9
+ * It provides a suggest behavior, where the user can type a few letters and the component will suggest possible matches.
10
+ * It can be used with a variety of data providers, such as an API.
11
+ * It is fully customizable, so you can change the look and feel of the component to match your needs.
12
+
13
+ If you are looking for a component to provide a suggest behavior, the input-autocomplete component is a good option.
14
+
15
+
16
+
17
+ ## Simple Example
18
+
19
+ In this example, the input will use its name as the search parameter when calling the service responsible for autocompletion.
20
+
21
+ The template is used to render the list items of results.
22
+ The list items are responsible for making a selection.
23
+
24
+ This time, we added buttons with the same name as the input while keeping the same data provider.
25
+ The result is that when you select an item, the input takes the value of the selected item, completing the classic suggest behavior.
26
+
27
+
28
+ <sonic-code>
29
+ <template>
30
+ <sonic-input-autocomplete
31
+ class="w-64"
32
+ label="A french city name"
33
+ formDataProvider="autoComplete-example-base"
34
+ name="nom"
35
+ placeholder="Paris, Lyon, Tours, ..."
36
+ serviceurl="https://geo.api.gouv.fr"
37
+ dataproviderexpression="communes?limit=5&boost=population"
38
+ >
39
+ <template>
40
+ <sonic-menu-item debug radio name="nom" data-bind ::inner-html="$nom" ::value="$nom"></sonic-menu-item>
41
+ </template>
42
+ </sonic-input-autocomplete>
43
+ </template>
44
+ </sonic-code>
45
+
46
+
47
+ ## Value different from search parameter
48
+
49
+ In this example, the search parameter is separated from the name of the input. This means that the input will use the name "nom" as the search parameter, but the form data provider will be filled with the data named "siren" from the selected list item.
50
+
51
+ To do this, we need to use the `searchParam` attribute on the input element. This attribute specifies the name of the search parameter that will be used.
52
+
53
+ We also need to use the `name` and `value` attribute on the list items. This attribute specifies the value of the data provider that will be used for the selected list item.
54
+
55
+ By using these attributes, we can separate the search parameter from the name of the input and still fill the form data provider with the data from the selected list item.
56
+
57
+
58
+ <sonic-code>
59
+ <template>
60
+ <sonic-input-autocomplete
61
+ class="w-64"
62
+ label="A french city name"
63
+ formDataProvider="autoComplete-example"
64
+ name="siren"
65
+ value="212703771"
66
+ placeholder="Paris, Lyon, Tours, ..."
67
+ serviceurl="https://geo.api.gouv.fr"
68
+ dataproviderexpression="communes?limit=5&boost=population"
69
+ searchParameter="nom"
70
+ >
71
+ <template>
72
+ <sonic-menu-item debug radio name="siren" data-bind ::inner-html="$nom" ::value="$siren"></sonic-menu-item>
73
+ </template>
74
+ </sonic-input-autocomplete>
75
+ </template>
76
+ </sonic-code>
77
+
78
+
79
+ ## Select autocomplete / value different from search parameter
80
+
81
+ This example is the same as the previous one, except that the `select` attribute is used. This attribute changes the look and feel of the component slightly.
82
+
83
+ Now the text is less free because, you must select either something from the list given by the service, or nothing else.
84
+
85
+ The following code shows how to use the `select` attribute in an autocomplete input:
86
+
87
+ <sonic-code>
88
+ <template>
89
+ <sonic-input-autocomplete
90
+ select
91
+ class="w-64"
92
+ label="A french city name"
93
+ formDataProvider="autoComplete-example2"
94
+ name="siren"
95
+ value="212703771"
96
+ placeholder="Paris, Lyon, Tours, ..."
97
+ serviceurl="https://geo.api.gouv.fr"
98
+ dataproviderexpression="communes?limit=5&boost=population"
99
+ searchParameter="nom"
100
+ >
101
+ <template>
102
+ <sonic-menu-item debug radio name="siren" data-bind ::inner-html="$nom" ::value="$siren"></sonic-menu-item>
103
+ </template>
104
+ </sonic-input-autocomplete>
105
+ </template>
106
+ </sonic-code>
107
+
108
+ ## keyboard navigation
109
+
110
+ At the moment you can enable keyboard up/down by adding an attribut "data-keyboard-nav" on the component and its listItems
111
+
112
+ <sonic-code>
113
+ <template>
114
+ <sonic-input-autocomplete
115
+ class="w-64"
116
+ label="A french city name"
117
+ formDataProvider="autoComplete-example-keyboard"
118
+ name="nom"
119
+ data-keyboard-nav="nav-autocomplete"
120
+ placeholder="Paris, Lyon, Tours, ..."
121
+ serviceurl="https://geo.api.gouv.fr"
122
+ dataproviderexpression="communes?limit=60&boost=population"
123
+ >
124
+ <template>
125
+ <sonic-menu-item debug radio name="nom" data-keyboard-nav="nav-autocomplete" data-bind ::inner-html="$nom" ::value="$nom"></sonic-menu-item>
126
+ </template>
127
+ </sonic-input-autocomplete>
128
+ </template>
129
+ </sonic-code>
130
+
@@ -0,0 +1,84 @@
1
+ # Radio
2
+
3
+ ## Size
4
+ <sonic-code>
5
+ <template>
6
+ <div class="grid gap-2" formDataProvider="radioSizeExemple">
7
+ <sonic-radio name="size" value="2xs" size="2xs">2xs radio</sonic-radio>
8
+ <sonic-radio name="size" value="xs" size="xs">xs radio</sonic-radio>
9
+ <sonic-radio name="size" value="sm" size="sm">sm radio</sonic-radio>
10
+ <sonic-radio name="size" value="default" >default radio</sonic-radio>
11
+ <sonic-radio name="size" value="lg" size="lg">lg radio</sonic-radio>
12
+ <sonic-radio name="size" value="xl" size="xl">xl radio</sonic-radio>
13
+ <sonic-radio name="size" value="2xl" size="2xl">2xl radio</sonic-radio>
14
+ </div>
15
+ </template>
16
+ </sonic-code>
17
+
18
+ ## Checked
19
+ <sonic-code>
20
+ <template>
21
+ <sonic-radio checked
22
+ >Already checked radio
23
+ </sonic-radio>
24
+ </template>
25
+ </sonic-code>
26
+
27
+ ## Disabled
28
+ <sonic-code>
29
+ <template>
30
+ <sonic-radio disabled
31
+ >Disabled radio
32
+ </sonic-radio>
33
+ </template>
34
+ </sonic-code>
35
+
36
+ ## Disabled and checked
37
+ <sonic-code>
38
+ <template>
39
+ <sonic-radio disabled checked
40
+ >Disabled but already checked radio
41
+ </sonic-radio>
42
+ </template>
43
+ </sonic-code>
44
+
45
+ ## radio with link
46
+ <sonic-code>
47
+ <template>
48
+ <sonic-radio name="link" value="link">radio with <sonic-link href="#" class="underline text-info">link</sonic-link>
49
+ </template>
50
+ </sonic-code>
51
+
52
+
53
+ ## Example of use
54
+ <sonic-code>
55
+ <template>
56
+ <sonic-subscriber dataProvider="jokeFilterRadio" class="text-xl my-4 block font-bold">
57
+ Remove following jokes :
58
+ <sonic-value key="blacklistFlags" class="block text-sm"></sonic-value>
59
+ </sonic-subscriber>
60
+ <div formDataProvider="jokeFilterRadio" class="grid grid-cols-2 lg:grid-cols-3 gap-x-6 gap-y-2 mt-2 mb-3">
61
+ <sonic-radio name="blacklistFlags" value="nsfw">nsfw</sonic-radio>
62
+ <sonic-radio name="blacklistFlags" value="religious">religious</sonic-radio>
63
+ <sonic-radio name="blacklistFlags" value="political">political</sonic-radio>
64
+ <sonic-radio name="blacklistFlags" value="racist" checked >racist</sonic-radio>
65
+ <sonic-radio name="blacklistFlags" value="sexist" >sexist</sonic-radio>
66
+ <sonic-radio name="blacklistFlags" value="explicit">explicit</sonic-radio>
67
+ </div>
68
+ <sonic-queue
69
+ lazyload
70
+ dataProviderExpression="joke/Any?amount=10&lang=en"
71
+ dataFilterProvider="jokeFilterRadio"
72
+ serviceURL="https://v2.jokeapi.dev"
73
+ key="jokes"
74
+ >
75
+ <template>
76
+ <div class="border-0 border-b-[1px] border-b-neutral-300 py-3 leading-tight">
77
+ <sonic-value key="joke"></sonic-value>
78
+ <sonic-value key="setup" class="font-bold"></sonic-value><br>
79
+ <sonic-value key="delivery"></sonic-value>
80
+ </div>
81
+ </template>
82
+ </sonic-queue>
83
+ </template>
84
+ </sonic-code>
@@ -0,0 +1,97 @@
1
+ # Select
2
+
3
+ ## Options
4
+ <sonic-code>
5
+ <template>
6
+ <div class="grid gap-3">
7
+ <sonic-select>
8
+ <option value="">No Selection</option>
9
+ <option value="1">One</option>
10
+ <option value="2" selected>Two (set by "tag")</option>
11
+ <option value="3">Three</option>
12
+ </sonic-select>
13
+ <sonic-select options='[{"value":"", "wording":"Set options via \"attribute\""},
14
+ {"value":"dark", "wording":"dark (set by \"attribute\")", "selected" : "true"}, {"value":"auto", "wording":"auto"}
15
+ ]'>
16
+ </sonic-select>
17
+ </div>
18
+ </template>
19
+ </sonic-code>
20
+
21
+ ## Size
22
+ <sonic-code>
23
+ <template>
24
+ <div class="grid gap-3">
25
+ <sonic-select size="2xs"><option>2xs</option></sonic-select>
26
+ <sonic-select size="xs"><option>xs</option></sonic-select>
27
+ <sonic-select size="sm"><option>sm</option></sonic-select>
28
+ <sonic-select size="md"><option>md</option></sonic-select>
29
+ <sonic-select size="default"><option>default</option></sonic-select>
30
+ <sonic-select size="lg"><option>lg</option></sonic-select>
31
+ <sonic-select size="xl"><option>xl</option></sonic-select>
32
+ <sonic-select size="2xl"><option>2xl</option></sonic-select>
33
+ </div>
34
+ </template>
35
+ </sonic-code>
36
+
37
+
38
+ ## Multiple
39
+ <sonic-code>
40
+ <template>
41
+ <div class="grid gap-3">
42
+ <sonic-select multiple>
43
+ <option value="">Choose a number</option>
44
+ <option value="1">One</option>
45
+ <option value="2">Two</option>
46
+ <option value="3">Three</option>
47
+ </sonic-select>
48
+ </div>
49
+ </template>
50
+ </sonic-code>
51
+
52
+
53
+ ## Disabled
54
+ <sonic-code>
55
+ <template>
56
+ <div class="grid gap-3">
57
+ <sonic-select disabled>
58
+ <option value="">Choose a number</option>
59
+ <option value="1">One</option>
60
+ <option value="2">Two</option>
61
+ <option value="3">Three</option>
62
+ </sonic-select>
63
+ </div>
64
+ </template>
65
+ </sonic-code>
66
+
67
+ ## Example of use
68
+ <sonic-code>
69
+ <template>
70
+ <sonic-select
71
+ formDataProvider="select-filter"
72
+ name="lang"
73
+ value="fr"
74
+ >
75
+ <option value="fr">fr<option>
76
+ <optionn value="en">en<option>
77
+ </sonic-select>
78
+ <sonic-subscriber dataProvider="select-filter" class="text-xl my-4 block font-bold">
79
+ Blagues trouvées pour le code de langue"<span data-bind ::inner-html="$lang"></span>" :
80
+ </sonic-subscriber>
81
+ <sonic-queue
82
+ lazyload
83
+ dataProviderExpression="joke/Any?amount=10"
84
+ dataFilterProvider="select-filter"
85
+ serviceURL="https://v2.jokeapi.dev"
86
+ key="jokes"
87
+ >
88
+ <template>
89
+ <div class="border-0 border-b-[1px] border-b-neutral-300 border-dotted py-3">
90
+ <div data-bind ::inner-html="$joke"></div>
91
+ <div data-bind ::inner-html="$setup"></div>
92
+ <div data-bind ::inner-html="$delivery"></div>
93
+ </div>
94
+ </template>
95
+ </sonic-queue>
96
+ </template>
97
+ </sonic-code>
@@ -0,0 +1,84 @@
1
+ # Switch
2
+
3
+ ## Size
4
+ <sonic-code>
5
+ <template>
6
+ <div class="grid gap-2" formDataProvider="switchSizeExemple">
7
+ <sonic-switch name="size2xs" value="2xs" size="2xs">2xs switch</sonic-switch>
8
+ <sonic-switch name="sizexs" value="xs" size="xs">xs switch</sonic-switch>
9
+ <sonic-switch name="sizesm" value="sm" size="sm">sm switch</sonic-switch>
10
+ <sonic-switch name="size" value="default" >default switch</sonic-switch>
11
+ <sonic-switch name="sizelg" value="lg" size="lg">lg switch</sonic-switch>
12
+ <sonic-switch name="sizexl" value="xl" size="xl">xl switch</sonic-switch>
13
+ <sonic-switch name="size2xl" value="2xl" size="2xl">2xl switch</sonic-switch>
14
+ </div>
15
+ </template>
16
+ </sonic-code>
17
+
18
+ ## Checked
19
+ <sonic-code>
20
+ <template>
21
+ <sonic-switch checked
22
+ >Already checked switch
23
+ </sonic-switch>
24
+ </template>
25
+ </sonic-code>
26
+
27
+ ## Disabled
28
+ <sonic-code>
29
+ <template>
30
+ <sonic-switch disabled
31
+ >Disabled switch
32
+ </sonic-switch>
33
+ </template>
34
+ </sonic-code>
35
+
36
+ ## Disabled and checked
37
+ <sonic-code>
38
+ <template>
39
+ <sonic-switch disabled checked
40
+ >Disabled but already checked switch
41
+ </sonic-switch>
42
+ </template>
43
+ </sonic-code>
44
+
45
+ ## switch with link
46
+ <sonic-code>
47
+ <template>
48
+ <sonic-switch name="link" value="link">switch with <sonic-link href="#" class="underline text-info">link</sonic-link>
49
+ </template>
50
+ </sonic-code>
51
+
52
+
53
+ ## Example of use
54
+ <sonic-code>
55
+ <template>
56
+ <sonic-subscriber dataProvider="jokeFilterswitch" class="text-xl my-4 block font-bold">
57
+ Remove following jokes :
58
+ <sonic-value key="blacklistFlags" class="block text-sm"></sonic-value>
59
+ </sonic-subscriber>
60
+ <div formDataProvider="jokeFilterswitch" class="grid grid-cols-2 lg:grid-cols-3 gap-x-6 gap-y-2 mt-2 mb-3">
61
+ <sonic-switch name="blacklistFlags" value="nsfw">nsfw</sonic-switch>
62
+ <sonic-switch name="blacklistFlags" value="religious">religious</sonic-switch>
63
+ <sonic-switch name="blacklistFlags" value="political">political</sonic-switch>
64
+ <sonic-switch name="blacklistFlags" value="racist" checked >racist</sonic-switch>
65
+ <sonic-switch name="blacklistFlags" value="sexist" >sexist</sonic-switch>
66
+ <sonic-switch name="blacklistFlags" value="explicit">explicit</sonic-switch>
67
+ </div>
68
+ <sonic-queue
69
+ lazyload
70
+ dataProviderExpression="joke/Any?amount=10&lang=en"
71
+ dataFilterProvider="jokeFilterswitch"
72
+ serviceURL="https://v2.jokeapi.dev"
73
+ key="jokes"
74
+ >
75
+ <template>
76
+ <div class="border-0 border-b-[1px] border-b-neutral-300 py-3 leading-tight">
77
+ <sonic-value key="joke"></sonic-value>
78
+ <sonic-value key="setup" class="font-bold"></sonic-value><br>
79
+ <sonic-value key="delivery"></sonic-value>
80
+ </div>
81
+ </template>
82
+ </sonic-queue>
83
+ </template>
84
+ </sonic-code>
@@ -0,0 +1,65 @@
1
+ # Textarea
2
+
3
+ <sonic-button type="info" size="sm" target="_blank" href="https://www.w3schools.com/tags/tag_textarea.asp#midcontentadcontainer">
4
+ <sonic-icon library="iconoir" name="open-new-window" slot="prefix" ></sonic-icon>
5
+ Native attibutes list
6
+ </sonic-button>
7
+
8
+
9
+ ## Label
10
+ <sonic-code>
11
+ <template>
12
+ <sonic-textarea label="Label"></sonic-textarea>
13
+ </template>
14
+ </sonic-code>
15
+
16
+ ## Placeholder
17
+ <sonic-code>
18
+ <template>
19
+ <sonic-textarea placeholder="placeholder"></sonic-textarea>
20
+ </template>
21
+ </sonic-code>
22
+
23
+ ## Value
24
+ <sonic-code>
25
+ <template>
26
+ <sonic-textarea value="value"></sonic-textarea>
27
+ </template>
28
+ </sonic-code>
29
+
30
+ ## Required
31
+ <sonic-code>
32
+ <template>
33
+ <sonic-textarea required label="Feedback on blur" placeholder="required" ></sonic-textarea>
34
+ </template>
35
+ </sonic-code>
36
+
37
+ ## Rows
38
+ <sonic-code>
39
+ <template>
40
+ <sonic-textarea rows="8"></sonic-textarea>
41
+ </template>
42
+ </sonic-code>
43
+
44
+ ## Description
45
+ <sonic-code>
46
+ <template>
47
+ <sonic-textarea description="Description goes here" ></sonic-textarea>
48
+ </template>
49
+ </sonic-code>
50
+
51
+
52
+ ## Size
53
+ <sonic-code>
54
+ <template>
55
+ <div class="grid gap-4">
56
+ <sonic-textarea size="2xs" value="2xs"></sonic-textarea>
57
+ <sonic-textarea size="xs" value="xs"></sonic-textarea>
58
+ <sonic-textarea size="sm" value="sm"></sonic-textarea>
59
+ <sonic-textarea value="md / default"></sonic-textarea>
60
+ <sonic-textarea size="lg" value="lg"></sonic-textarea>
61
+ <sonic-textarea size="xl" value="xl"></sonic-textarea>
62
+ <sonic-textarea size="2xl" value="2xl"></sonic-textarea>
63
+ </div>
64
+ </template>
65
+ </sonic-code>
@@ -0,0 +1,75 @@
1
+ # Group
2
+
3
+ ## Radio group
4
+ <sonic-code>
5
+ <template>
6
+ <sonic-group formDataProvider="subscriptionData">
7
+ <sonic-button radio name="subscription" value="standard" type="default">😎 Standard</sonic-button>
8
+ <sonic-button radio checked name="subscription" value="premium" type="default">⭐ Premium</sonic-button>
9
+ <sonic-button radio name="subscription" value="diamond" type="default">💎 Diamond</sonic-button>
10
+ </sonic-group>
11
+ </template>
12
+ </sonic-code>
13
+
14
+ ## Button group
15
+ <sonic-code>
16
+ <template>
17
+ <sonic-group>
18
+ <sonic-button type="info" target="_blank" href="https://wwws.airfrance.fr/">🗼Air France</sonic-button>
19
+ <sonic-button type="success" target="_blank" href="https://www.airtahitinui.com/">🌴 Air Tahiti</sonic-button>
20
+ <sonic-button type="danger" target="_blank" href="https://www.aircorsica.com/">💣 Air Corsica</sonic-button>
21
+ </sonic-group>
22
+ </template>
23
+ </sonic-code>
24
+
25
+ ## Input actions prefix
26
+ <sonic-code>
27
+ <template>
28
+ <div class="grid grid-cols-3 gap-3">
29
+ <sonic-group>
30
+ <sonic-button type="info" shape="square">
31
+ <sonic-icon library="iconoir" library="iconoir" name="info-empty"></sonic-icon>
32
+ </sonic-button>
33
+ <sonic-input placeholder="placeholder" ></sonic-input>
34
+ </sonic-group>
35
+ <sonic-group label="Label">
36
+ <sonic-button type="info" shape="square">
37
+ <sonic-icon library="iconoir" library="iconoir" name="info-empty"></sonic-icon>
38
+ </sonic-button>
39
+ <sonic-input ></sonic-input>
40
+ </sonic-group>
41
+ <sonic-group description="Description">
42
+ <sonic-button type="info" shape="square">
43
+ <sonic-icon library="iconoir" library="iconoir" name="info-empty"></sonic-icon>
44
+ </sonic-button>
45
+ <sonic-input ></sonic-input>
46
+ </sonic-group>
47
+ </div>
48
+ </template>
49
+ </sonic-code>
50
+
51
+ ## Input actions suffix
52
+ <sonic-code>
53
+ <template>
54
+ <div class="grid grid-cols-3 gap-3">
55
+ <sonic-group>
56
+ <sonic-input placeholder="placeholder" ></sonic-input>
57
+ <sonic-button type="primary" shape="square">
58
+ <sonic-icon library="iconoir" library="iconoir" name="check"></sonic-icon>
59
+ </sonic-button>
60
+ </sonic-group>
61
+ <sonic-group label="Label">
62
+ <sonic-input ></sonic-input>
63
+ <sonic-button type="primary" shape="square">
64
+ <sonic-icon library="iconoir" library="iconoir" name="check"></sonic-icon>
65
+ </sonic-button>
66
+ </sonic-group>
67
+ <sonic-group description="Description">
68
+ <sonic-input ></sonic-input>
69
+ <sonic-button type="primary" shape="square">
70
+ <sonic-icon library="iconoir" library="iconoir" name="check"></sonic-icon>
71
+ </sonic-button>
72
+ </sonic-group>
73
+ </div>
74
+ </template>
75
+ </sonic-code>
@@ -0,0 +1,125 @@
1
+ # Icon
2
+
3
+
4
+ ## Custom
5
+
6
+ <p >Icons located in the following folder : <span class="text-info">/svg/$prefix/$name.svg<span></p>
7
+
8
+ <sonic-code customIconLibraryPath="/svg/$prefix/$name.svg"
9
+ customIconDefaultPrefix="regular">
10
+ <template>
11
+ <sonic-scope customIconLibraryPath="/svg/$prefix/$name.svg"
12
+ customIconDefaultPrefix="regular">
13
+ <div class="grid grid-cols-2 sm:grid-cols-3 lg:grid-cols-4 gap-8">
14
+ <div class="text-center">
15
+ <sonic-icon library="custom" prefix="regular" name="plane"></sonic-icon>
16
+ <br>
17
+ <div class="text-xs mt-1">regular</div>
18
+ </div>
19
+ <div class="text-center">
20
+ <sonic-icon library="custom" prefix="solid" name="plane"></sonic-icon>
21
+ <br>
22
+ <div class="text-xs mt-1">solid</div>
23
+ </div>
24
+ <div class="text-center">
25
+ <sonic-icon library="custom" name="plane"></sonic-icon>
26
+ <br>
27
+ <div class="text-xs mt-1">default prefix</div>
28
+ </div>
29
+ </div>
30
+ </sonic-scope>
31
+ </template>
32
+ </sonic-code>
33
+
34
+
35
+ ## External
36
+ <sonic-code>
37
+ <template>
38
+ <div class="grid grid-cols-2 sm:grid-cols-3 lg:grid-cols-4 gap-8">
39
+ <sonic-link href="https://heroicons.com/" target="_blank" class="text-center underline">
40
+ <sonic-icon library="heroicons" prefix="outline" name="academic-cap" size="lg"></sonic-icon>
41
+ <br>
42
+ <div class="text-xs mt-1">heroicons</div>
43
+ </sonic-link>
44
+ <sonic-link href="https://iconoir.com/" target="_blank" class="text-center underline">
45
+ <sonic-icon library="iconoir" name="2x2-cell" size="lg"></sonic-icon>
46
+ <br>
47
+ <div class="text-xs mt-1">iconoir</div>
48
+ </sonic-link>
49
+ <sonic-link href="https://materialdesignicons.com/" target="_blank" class="text-center underline">
50
+ <sonic-icon library="material" prefix="outline" name="email" size="lg"></sonic-icon>
51
+ <br>
52
+ <div class="text-xs mt-1">material design</div>
53
+ </sonic-link>
54
+ <sonic-link href="https://fontawesome.com/search?o=r&m=free&s=regular" target="_blank" class="text-center underline">
55
+ <sonic-icon library="fontAwesome" prefix="regular" name="user" size="lg"></sonic-icon>
56
+ <br>
57
+ <div class="text-xs mt-1">fontAwesome regular</div>
58
+ </sonic-link>
59
+ <sonic-link href="https://fontawesome.com/search?o=r&m=free&s=solid" target="_blank" class="text-center underline">
60
+ <sonic-icon library="fontAwesome" prefix="solid" name="book" size="lg"></sonic-icon>
61
+ <br>
62
+ <div class="text-xs mt-1">fontAwesome solid</div>
63
+ </sonic-link>
64
+ <sonic-link href="https://feathericons.com/" target="_blank" class="text-center underline">
65
+ <sonic-icon library="feathers" name="activity" size="lg"></sonic-icon>
66
+ <br>
67
+ <div class="text-xs mt-1">feathers</div>
68
+ </sonic-link>
69
+ <sonic-link href="https://lucide.dev/" target="_blank" class="text-center underline">
70
+ <sonic-icon library="lucide" name="album" size="lg"></sonic-icon>
71
+ <br>
72
+ <div class="text-xs mt-1">lucide</div>
73
+ </sonic-link>
74
+ </div>
75
+ </template>
76
+ </sonic-code>
77
+
78
+ ## Size
79
+ <sonic-code>
80
+ <template>
81
+ <div class="grid grid-cols-2 sm:grid-cols-3 lg:grid-cols-4 gap-8">
82
+ <div class="text-center">
83
+ <sonic-icon library="heroicons" prefix="outline" name="academic-cap" size="2xs"></sonic-icon>
84
+ <br>
85
+ <div class="text-xs mt-1">2xs</div>
86
+ </div>
87
+ <div class="text-center">
88
+ <sonic-icon library="heroicons" prefix="outline" name="academic-cap" size="xs"></sonic-icon>
89
+ <br>
90
+ <div class="text-xs mt-1">xs</div>
91
+ </div>
92
+ <div class="text-center">
93
+ <sonic-icon library="heroicons" prefix="outline" name="academic-cap" size="sm"></sonic-icon>
94
+ <br>
95
+ <div class="text-xs mt-1">sm</div>
96
+ </div>
97
+ <div class="text-center">
98
+ <sonic-icon library="heroicons" prefix="outline" name="academic-cap"></sonic-icon>
99
+ <br>
100
+ <div class="text-xs mt-1">default</div>
101
+ </div>
102
+ <div class="text-center">
103
+ <sonic-icon library="heroicons" prefix="outline" name="academic-cap" size="lg"></sonic-icon>
104
+ <br>
105
+ <div class="text-xs mt-1">lg</div>
106
+ </div>
107
+ <div class="text-center">
108
+ <sonic-icon library="heroicons" prefix="outline" name="academic-cap" size="xl"></sonic-icon>
109
+ <br>
110
+ <div class="text-xs mt-1">xl</div>
111
+ </div>
112
+ <div class="text-center">
113
+ <sonic-icon library="heroicons" prefix="outline" name="academic-cap" size="2xl"></sonic-icon>
114
+ <br>
115
+ <div class="text-xs mt-1">2xl</div>
116
+ </div>
117
+ <div class="text-center">
118
+ <sonic-icon library="heroicons" prefix="outline" name="academic-cap" size="3xl"></sonic-icon>
119
+ <br>
120
+ <div class="text-xs mt-1">3xl</div>
121
+ </div>
122
+ </div>
123
+ </template>
124
+ </sonic-code>
125
+