@propelinc/citrus-ui 1.0.2 → 1.0.3

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.
package/README.md CHANGED
@@ -19,19 +19,12 @@ Questions? Ask for eng help in [#unit-eng-frontend-libraries](https://propel-tea
19
19
 
20
20
  citrus-ui publishes two builds:
21
21
 
22
- | Build | File | Description |
23
- | ------- | -------------------- | ---------------------------------------------------------------------------------------------------- |
24
- | **npm** | `dist/index.mjs` | Dependencies externalized — for bundler-based projects |
25
- | **CDN** | `dist/index.cdn.mjs` | Shoelace, dayjs, lodash, maska, and scroll-into-view-if-needed bundled in — for `<script>` tag usage |
22
+ | Build | File | Description |
23
+ | ------- | -------------------- | --------------------------------------------------------------------------------- |
24
+ | **npm** | `dist/index.mjs` | Dependencies externalized — for bundler-based projects |
25
+ | **CDN** | `dist/index.cdn.mjs` | All dependencies bundled except `vue` and `vue-router` — for `<script>` tag usage |
26
26
 
27
- The CDN build still requires these peer dependencies to be loaded separately:
28
-
29
- - `vue`
30
- - `@fortawesome/*` (see [CDN challenges](#cdn-challenges))
31
- - `core-js`
32
- - `i18next`
33
-
34
- > **Note:** `@fortawesome/pro-*` packages require a paid FontAwesome Pro license and are not available on public CDNs. Components that use icons (`CButton`, `CLabel`, `CCheckbox`, `CTextField`, `CSelect`, and others) will not render icons without FontAwesome Pro. See [CDN challenges](#cdn-challenges) below.
27
+ The CDN build only requires `vue` and `vue-router` to be loaded separately. Everything else (Shoelace, FontAwesome, dayjs, lodash, maska, scroll-into-view-if-needed, core-js, i18next) is bundled in.
35
28
 
36
29
  ```html
37
30
  <!-- Shoelace styles + assets (still needed for CSS/icons, but JS is bundled) -->
@@ -40,9 +33,6 @@ The CDN build still requires these peer dependencies to be loaded separately:
40
33
  href="https://cdn.jsdelivr.net/npm/@shoelace-style/shoelace@2.15.0/cdn/themes/light.css"
41
34
  />
42
35
 
43
- <!-- FontAwesome Pro (self-hosted — not available on public CDNs) -->
44
- <script src="YOUR_SELF_HOSTED_FONTAWESOME_PRO_URL"></script>
45
-
46
36
  <!-- citrus-ui styles -->
47
37
  <link
48
38
  rel="stylesheet"
@@ -52,21 +42,24 @@ The CDN build still requires these peer dependencies to be loaded separately:
52
42
  <!-- citrus-ui + Vue -->
53
43
  <script type="module">
54
44
  import { createApp } from 'https://cdn.jsdelivr.net/npm/vue@3/dist/vue.esm-browser.prod.js';
45
+ import {
46
+ createRouter,
47
+ createWebHistory,
48
+ } from 'https://cdn.jsdelivr.net/npm/vue-router@4/dist/vue-router.esm-browser.js';
55
49
  import CitrusUi from 'https://cdn.jsdelivr.net/npm/@propelinc/citrus-ui/dist/index.cdn.mjs';
56
50
 
51
+ const router = createRouter({
52
+ history: createWebHistory(),
53
+ routes: [
54
+ /* ... */
55
+ ],
56
+ });
57
+
57
58
  const app = createApp({
58
59
  /* ... */
59
60
  });
61
+ app.use(router);
60
62
  app.use(CitrusUi);
61
63
  app.mount('#app');
62
64
  </script>
63
65
  ```
64
-
65
- ### CDN Challenges
66
-
67
- | Dependency | CDN available? | Notes |
68
- | -------------------- | -------------- | ----------------------------------------------------- |
69
- | `vue` | ✅ | jsDelivr / unpkg |
70
- | `@fortawesome/pro-*` | ❌ | Paid license, not on public npm — must be self-hosted |
71
-
72
- All other dependencies (Shoelace, dayjs, lodash, maska, scroll-into-view-if-needed) are bundled into the CDN build and do not need to be loaded separately.