@castlabs/ui 4.18.2

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 (140) hide show
  1. package/README.md +94 -0
  2. package/dist/assets/castlabs-logo.svg +2 -0
  3. package/dist/assets/cookie.svg +1 -0
  4. package/dist/castlabs-ui-editor.common.js +23189 -0
  5. package/dist/castlabs-ui-editor.common.js.map +1 -0
  6. package/dist/castlabs-ui-editor.css +1 -0
  7. package/dist/castlabs-ui-editor.umd.js +23208 -0
  8. package/dist/castlabs-ui-editor.umd.js.map +1 -0
  9. package/dist/castlabs-ui-editor.umd.min.js +10 -0
  10. package/dist/castlabs-ui-editor.umd.min.js.map +1 -0
  11. package/dist/castlabs-ui.common.js +6828 -0
  12. package/dist/castlabs-ui.common.js.map +1 -0
  13. package/dist/castlabs-ui.core.js +1031 -0
  14. package/dist/castlabs-ui.css +12 -0
  15. package/dist/castlabs-ui.module.d.ts +83 -0
  16. package/dist/castlabs-ui.module.js +1031 -0
  17. package/dist/castlabs-ui.umd.js +6847 -0
  18. package/dist/castlabs-ui.umd.js.map +1 -0
  19. package/dist/castlabs-ui.umd.min.js +8 -0
  20. package/dist/castlabs-ui.umd.min.js.map +1 -0
  21. package/dist/demo.html +1 -0
  22. package/dist/favicon/192.png +0 -0
  23. package/dist/favicon/512.png +0 -0
  24. package/dist/favicon/apple-touch-icon.png +0 -0
  25. package/dist/favicon/favicon-unread.svg +75 -0
  26. package/dist/favicon/favicon.ico +0 -0
  27. package/dist/favicon/favicon.svg +43 -0
  28. package/dist/favicon/manifest.webmanifest +6 -0
  29. package/dist/fonts/BngRUXNETWXI6LwhGYvaxZikqbCCwR26eg.f31394d2.woff2 +0 -0
  30. package/dist/fonts/BngRUXNETWXI6LwhGYvaxZikqbCFwR26eg.00073a59.woff2 +0 -0
  31. package/dist/fonts/BngRUXNETWXI6LwhGYvaxZikqbCGwR0.faa92a75.woff2 +0 -0
  32. package/dist/fonts/BngRUXNETWXI6LwhGYvaxZikqbCIwR26eg.f8e38fba.woff2 +0 -0
  33. package/dist/fonts/BngRUXNETWXI6LwhGYvaxZikqbCJwR26eg.f1d5cd16.woff2 +0 -0
  34. package/dist/fonts/BngRUXNETWXI6LwhGYvaxZikqbCKwR26eg.ebbe259f.woff2 +0 -0
  35. package/dist/fonts/BngRUXNETWXI6LwhGYvaxZikqbCLwR26eg.e3d460d0.woff2 +0 -0
  36. package/dist/fonts/fa-brands-400.18993be8.woff2 +0 -0
  37. package/dist/fonts/fa-regular-400.e45bb696.woff2 +0 -0
  38. package/dist/fonts/fa-solid-900.16e3d2f0.woff2 +0 -0
  39. package/dist/fonts/mem6YaGs126MiZpBA-UFUK0Udc1UAw.6de93dc1.woff2 +0 -0
  40. package/dist/fonts/mem6YaGs126MiZpBA-UFUK0Wdc1UAw.55c9461f.woff2 +0 -0
  41. package/dist/fonts/mem6YaGs126MiZpBA-UFUK0Xdc1UAw.111f8c99.woff2 +0 -0
  42. package/dist/fonts/mem6YaGs126MiZpBA-UFUK0Zdc0.92257a03.woff2 +0 -0
  43. package/dist/fonts/mem6YaGs126MiZpBA-UFUK0adc1UAw.1844ded3.woff2 +0 -0
  44. package/dist/fonts/mem6YaGs126MiZpBA-UFUK0bdc1UAw.719267ea.woff2 +0 -0
  45. package/dist/fonts/mem6YaGs126MiZpBA-UFUK0ddc1UAw.037dea2d.woff2 +0 -0
  46. package/dist/fonts/mem8YaGs126MiZpBA-UFUZ0bbck.6869bd80.woff2 +0 -0
  47. package/dist/fonts/mem8YaGs126MiZpBA-UFV50bbck.05a41692.woff2 +0 -0
  48. package/dist/fonts/mem8YaGs126MiZpBA-UFVZ0b.38ffdf27.woff2 +0 -0
  49. package/dist/fonts/mem8YaGs126MiZpBA-UFVp0bbck.f12c0c2c.woff2 +0 -0
  50. package/dist/fonts/mem8YaGs126MiZpBA-UFW50bbck.03f14837.woff2 +0 -0
  51. package/dist/fonts/mem8YaGs126MiZpBA-UFWJ0bbck.abcca84a.woff2 +0 -0
  52. package/dist/fonts/mem8YaGs126MiZpBA-UFWp0bbck.4d1e267c.woff2 +0 -0
  53. package/package.json +71 -0
  54. package/plugins/uid/index.js +16 -0
  55. package/plugins/uid/index.ts +16 -0
  56. package/src/assets/castlabs-logo.svg +2 -0
  57. package/src/assets/cookie.svg +1 -0
  58. package/src/components/ClAlert/style.scss +117 -0
  59. package/src/components/ClBadge/style.scss +122 -0
  60. package/src/components/ClButton/style.scss +338 -0
  61. package/src/components/ClCard/style.scss +61 -0
  62. package/src/components/ClCard/style.variables.scss +179 -0
  63. package/src/components/ClDropdown/style.scss +272 -0
  64. package/src/components/ClDropzone/style.scss +21 -0
  65. package/src/components/ClFooter/style.scss +119 -0
  66. package/src/components/ClIcon/style.scss +58 -0
  67. package/src/components/ClIconotron/style.scss +86 -0
  68. package/src/components/ClList/style.scss +93 -0
  69. package/src/components/ClList/style.variables.scss +133 -0
  70. package/src/components/ClListGroup/style.scss +9 -0
  71. package/src/components/ClPagination/style.scss +123 -0
  72. package/src/components/ClProgress/style.scss +49 -0
  73. package/src/components/ClScrollbar/style.scss +14 -0
  74. package/src/components/ClSpinner/style.scss +26 -0
  75. package/src/components/ClTabs/style.scss +90 -0
  76. package/src/components/ClToggle/style.scss +97 -0
  77. package/src/components/ClTooltip/style.scss +46 -0
  78. package/src/components/ClWizard/style.scss +173 -0
  79. package/src/components/form/ClField/style.scss +45 -0
  80. package/src/components/form/ClFieldCheck/style.scss +99 -0
  81. package/src/components/form/ClFieldFile/style.scss +71 -0
  82. package/src/components/form/ClFieldGroup/style.scss +73 -0
  83. package/src/components/form/ClFieldInput/style.scss +118 -0
  84. package/src/components/form/ClFieldSelect/style.scss +39 -0
  85. package/src/components/form/ClFieldSet/style.scss +16 -0
  86. package/src/components/form/ClForm/style.scss +87 -0
  87. package/src/components/modal/ClModal/style.scss +138 -0
  88. package/src/components/navigation/ClNavSide/ClNavDrawer/style.scss +444 -0
  89. package/src/components/navigation/ClNavSide/ClNavSideMenu/style.scss +51 -0
  90. package/src/components/navigation/ClNavSide/style.scss +81 -0
  91. package/src/components/navigation/ClNavTop/style.scss +305 -0
  92. package/src/components/section/ClSectionHeadline/style.scss +49 -0
  93. package/src/components/section/ClSectionMainSide/style.scss +60 -0
  94. package/src/components/table/ClTable/style.scss +23 -0
  95. package/src/components/table/ClTable/style.variables.scss +155 -0
  96. package/src/components/table/ClTableCel/Actions/style.scss +11 -0
  97. package/src/components/table/ClTableCel/Audit/style.scss +26 -0
  98. package/src/components/table/ClTableCel/Boolean/style.scss +12 -0
  99. package/src/components/table/ClTableCel/Checkbox/style.scss +18 -0
  100. package/src/components/table/ClTableCel/Code/style.scss +13 -0
  101. package/src/components/table/ClTableCel/Currency/style.scss +9 -0
  102. package/src/components/table/ClTableCel/Date/style.scss +12 -0
  103. package/src/components/table/ClTableCel/ID/style.scss +16 -0
  104. package/src/components/table/ClTableCel/Links/style.scss +44 -0
  105. package/src/components/table/ClTableCel/style.scss +7 -0
  106. package/src/components/table/ClTableCel/style.variables.scss +25 -0
  107. package/src/components/table/ClTableFootChecked/style.scss +2 -0
  108. package/src/components/table/ClTableHead/style.scss +36 -0
  109. package/src/components/text/ClCopy/style.scss +42 -0
  110. package/src/components/text/ClHashtag/style.scss +31 -0
  111. package/src/components/text/ClLinkExternal/style.scss +147 -0
  112. package/src/components/text/ClOrg/style.scss +40 -0
  113. package/src/components/text/ClPlan/style.scss +35 -0
  114. package/src/components/text/ClRole/style.scss +39 -0
  115. package/src/components/widget/ClBackCancelOk/style.scss +3 -0
  116. package/src/components/widget/ClCookieBanner/style.scss +40 -0
  117. package/src/components/widget/ClPage/style.scss +11 -0
  118. package/src/fonts/FontAwesome5/FontAwesome5.scss +6121 -0
  119. package/src/fonts/NotoSansMono/NotoSansMono.scss +82 -0
  120. package/src/fonts/OpenSansVariable/OpenSansVariable.scss +183 -0
  121. package/src/styles/_global.scss +70 -0
  122. package/src/styles/abstracts/color.scss +127 -0
  123. package/src/styles/abstracts/layer.scss +10 -0
  124. package/src/styles/abstracts/spacing.scss +35 -0
  125. package/src/styles/abstracts/tools.scss +117 -0
  126. package/src/styles/assets/logo.scss +22 -0
  127. package/src/styles/components/button.variables.scss +18 -0
  128. package/src/styles/components/form.variables.scss +51 -0
  129. package/src/styles/layout/animation.scss +39 -0
  130. package/src/styles/layout/grid.scss +144 -0
  131. package/src/styles/layout/grid.variables.scss +50 -0
  132. package/src/styles/layout/section.scss +90 -0
  133. package/src/styles/layout/spacing.scss +295 -0
  134. package/src/styles/layout/typography.scss +321 -0
  135. package/src/styles/layout/typography.variables.scss +363 -0
  136. package/src/styles/ui.scss +98 -0
  137. package/src/styles/vendors/bootstrap.scss +28 -0
  138. package/src/styles/vendors/castlabs.scss +17 -0
  139. package/types/castlabs-ui.module.d.ts +83 -0
  140. package/types/index.d.ts +140 -0
package/README.md ADDED
@@ -0,0 +1,94 @@
1
+ # castlabs-ui
2
+
3
+ This is a vanilla HTML and Vue.js component library for castLabs branded sites.
4
+
5
+
6
+ ## Using `@castlabs/ui` in npm projects
7
+
8
+ This is a public NPM package, add it via:
9
+
10
+ * `npm install @castlabs/ui`
11
+
12
+
13
+ ## Using `@castlabs/ui` in Vue.js 3 projects
14
+
15
+ First create a vite Vue project (see Vue homepage's Quickstart), then remove all default css files and components.
16
+
17
+ Next, follow the steps described above under *Using `@castlabs/ui` in npm projects*. Then edit your `main.js`/`main.ts` file and add:
18
+
19
+ ```
20
+ import '@castlabs/ui/dist/castlabs-ui.css'
21
+ import { castlabsUi } from '@castlabs/ui'
22
+ import { castlabsUiEditor } from '@castlabs/ui/dist/castlabs-ui-editor.common.js' // optional
23
+ import uid from '@castlabs/ui/plugins/uid'
24
+
25
+ ...
26
+
27
+ app.use(castlabsUi)
28
+ app.use(castlabsUiEditor) // optional
29
+ app.use(uid)
30
+ ```
31
+
32
+ You now have access to all the `<cl-*>` components mentioned in the Styleguide and can start adding the page templates and the sidenav.
33
+
34
+
35
+ ## Using `@castlabs/ui` in Angular projects
36
+
37
+ Follow the steps described above under *Using `@castlabs/ui` in npm projects*. Then edit your `angular.json` file and add the style files to your `projects` section:
38
+
39
+ ```
40
+ "assets": [
41
+ { "glob": "favicon.ico", "input": "node_modules/@castlabs/ui/dist/favicon", "output": "/" },
42
+ { "glob": "favicon.svg", "input": "node_modules/@castlabs/ui/dist/favicon", "output": "/" },
43
+ { "glob": "*", "input": "node_modules/@castlabs/ui/dist/favicon", "output": "favicon/" },
44
+ "src/assets"
45
+ ],
46
+ "styles": [
47
+ "src/styles.scss"
48
+ ],
49
+ ```
50
+
51
+ Create/edit your `src/style.scss` file and add:
52
+
53
+ ```
54
+ $castlabs-ui-asset-prefix: '../..';
55
+ @import '@castlabs/ui/src/styles/ui';
56
+ ```
57
+
58
+ To use our `$cl-*` helper SCSS variables in a component `*.scss` file, add to its top:
59
+
60
+ ```
61
+ @import '@castlabs/ui/src/styles/global';
62
+ ```
63
+
64
+ To use our cl* helper js methods (csModalShow in the following examples), import them your TS files:
65
+
66
+ ```
67
+ import { clModalShow } from '@castlabs/ui/dist/castlabs-ui.module.js'
68
+ ```
69
+
70
+ You can use the helpers now in your code/template:
71
+
72
+ ```
73
+ <!-- TS --->
74
+ export class ... {
75
+ ...
76
+ clModalShow = (id: string): void => clModalShow(id)
77
+ ...
78
+ }
79
+
80
+ <!-- HTML --->
81
+ <button class="btn cl-btn-primary" (click)="clModalShow('mymodal')">click me</button>
82
+ ```
83
+
84
+ Finally, it might or might not necessary to copy `node_modules/@castlabs/ui/dist/castlabs-ui.module.d.ts` over into your source tree for your local IDE to pick up all types. The angular builder should be able to fetch them directly from the node module.
85
+
86
+
87
+ ## Which .js file to use
88
+
89
+ There are multiple variants of our library js available. Depending on your needs:
90
+
91
+ * `castlabs-ui.core.js` is used by static/vanilla JS projects that use <script> tags to load the file.
92
+ * `castlabs-ui.common.js` is used by Vue projects
93
+ * `castlabs-ui-editor.common.js` is used by Vue projects that also use the Ace editor.
94
+ * `castlabs-ui.module.js` is used by other frameworks that `import` JS files as JS modules.
@@ -0,0 +1,2 @@
1
+ <?xml version="1.0" encoding="UTF-8"?>
2
+ <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 250 50"><style type="text/css"> .st0{fill:#D2232A;} .st1{fill:#FFFFFF;} </style><rect class="st0" width="50" height="50"/><rect x="51.5" class="st0" width="198.5" height="50"/><path class="st1" d="M15 42.3c1.7-2.4 9.1-12.9 11.4-16.8 -0.8-2.3-6.5-14.8-7.9-17.2l2.2-1.7C23.8 10.8 31 21 34.5 25.5 32 28.1 21.3 39.3 16.8 44L15 42.3z"/><path class="st1" d="M72.4 39.3c-1 0.7-2.9 1.6-6 1.6 -4.3 0-8.8-2.5-8.8-8 0-7.2 5.1-10.3 9.7-10.3 1.8 0 3.5 0.4 4.4 1.1 0 0.8-0.4 1.9-1 2.8h-0.2c-0.6-0.8-2-2.1-4.4-2.1 -2.7 0-5 2.2-5 6.4 0 6 3.1 8.8 7.4 8.8 1.5 0 3.1-0.9 3.6-1.2L72.4 39.3z"/><path class="st1" d="M97.5 40c-0.5 0.3-1.3 0.9-2.9 0.9 -1.9 0-2.6-0.8-3-1.6 -1.2 0.8-2.6 1.6-5.6 1.6 -2.8 0-4.7-1.6-4.7-3.7 0-4.9 6.5-6.4 9.9-7.4V29c0-2.5-0.7-4.6-3.5-4.6 -3 0-4 2.4-4.7 3.8h-0.3c-0.4-0.5-0.7-0.8-1-1.5 1.1-1.5 3.5-4 7.6-4 4.3 0 5.2 2.3 5.2 6.1v5.4c0 2.6 0 5.5 2.1 5.5 0.4 0 0.5-0.1 0.7-0.2L97.5 40zM90.8 31.7c-2.2 0-5.9 0.9-5.9 4.5 0 2.2 1.4 3.4 3.5 3.4 1.7 0 2.6-1.2 2.9-1.5v-6.4H90.8z"/><path class="st1" d="M116.6 28.3c0-1.7-1.2-4.4-3.7-4.4 -1.4 0-2.4 1-2.4 2.7 0 4.3 8.4 3.1 8.4 9.1 0 3.6-2.9 5.3-6.5 5.3 -2.5 0-3.8-0.6-4.8-1.1 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5v-6.4H189.9z"/><path class="st1" d="M210.4 27.8L210.4 27.8c1.3-1.6 4-5.2 7.8-5.2 1.9 0 2.9 1.4 2.9 3.7 0 6.4-3.8 14.7-11.3 14.7 -2.4 0-3.6-1.2-3.6-3.4 0-1.2 0.3-2.8 0.6-4.5l2.8-14.7c0.1-0.7 0.3-1.7 0.3-2 0-0.5-0.2-0.8-0.6-0.8 -0.5 0-1.7 0.5-2.4 0.8l-0.3-0.8c1-0.7 4.2-2.3 5.5-2.3 0.6 0 0.9 0.3 0.9 1.1 0 0.5-0.2 1.5-0.3 2.5L210.4 27.8zM211.6 39.4c4.6 0 6.2-8.4 6.2-11.6 0-1.8-0.2-3.4-1.7-3.4 -2.9 0-6.7 6.5-6.7 11.6C209.4 37.9 210 39.4 211.6 39.4z"/><path class="st1" d="M240.7 28.3c0-1.7-1.2-4.4-3.7-4.4 -1.4 0-2.4 1-2.4 2.7 0 4.3 8.4 3.1 8.4 9.1 0 3.6-2.9 5.3-6.5 5.3 -2.5 0-3.8-0.6-4.8-1.1 -0.6-1.7-0.7-3.6-0.7-5.1h1c0.8 2.5 2 4.9 5.1 4.9 1.7 0 2.7-1.5 2.7-2.8 0-5.1-8.4-3.3-8.4-9.5 0-3.1 2.8-4.8 6-4.8 2 0 3.2 0.6 4 1.1 0.4 1.4 0.5 2.6 0.5 4.6H240.7z"/></svg>
@@ -0,0 +1 @@
1
+ <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 97 114" width="40" height="40"><style>.st0{fill:#e59b34}.st2{fill:#6a3000}</style><path class="st0" d="M83.2 46.9l-9.8-18.5c5.9-1.3 9.6-5.3 11.5-7.3l11.5 6.7c-1.8 2-13.2 19.1-13.2 19.1zM24.1 110.5C-26 91.1 11.8 15.1 48.6 0l11.5 6.7-36 103.8z"/><path class="st0" d="M63.6 26.6l-11-10.7c2.7 1.6 6.4 1.5 10.4-.7l11.5 6.7c-4 2.1-10.9 4.7-10.9 4.7z"/><path d="M96.4 27.9c3.1 29.3-16.9 64.8-42.1 79.7-23.5 13.6-42.6 2.7-42.7-24.3.3-29.3 21.3-64.7 48.5-76.6-2.7 10.8 2.7 21.2 14.4 15.2-.9 16.4 12.9 16 21.9 6z" fill="#ffb450"/><path class="st2" d="M68.7 76.3c-4.5 1.7-7.8 14.2 0 10.9 4.5-1.6 7.8-14.2 0-10.9zM48.8 63.8c12.2-4-2 20.7-4.7 8.2 0-3 2.1-6.7 4.7-8.2zM72.7 42.9c7.8-3.3 4.5 9.3 0 11-7.8 3.3-4.5-9.3 0-11zM33.8 88c7.8-3.3 4.5 9.3 0 10.9-7.7 3.4-4.4-9.2 0-10.9zM50.8 27.8c7.8-3.3 4.5 9.3 0 11-7.8 3.3-4.5-9.3 0-11zM30 54.7c12.2-4-2 20.7-4.8 8.2.1-3 2.2-6.7 4.8-8.2z"/></svg>