@davincihealthcare/elty-design-system-vue 1.8.0 → 1.9.1

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
@@ -21,11 +21,42 @@ in tailwind.config file
21
21
 
22
22
  module.exports = {
23
23
  ...
24
- plugins: [require('@davincihealthcare/elty-design-system-vue').EltyPlugin]
24
+ content: [..., './node_modules/@davincihealthcare/elty-design-system-vue/**/*.{tsx,js}'],
25
+ plugins: [
26
+ require('@tailwindcss/forms'),
27
+ require('@tailwindcss/typography'),
28
+ require('@davincihealthcare/elty-design-system-vue').EltyTailwindPlugin
29
+ ]
25
30
  ...
26
31
  }
27
32
  ```
28
33
 
34
+ Note: content needs a new entry in the array, alongside other you may already have.
35
+
36
+ Make sure to:
37
+
38
+ - NOT to import the elty foundations which are already imported alongside this plugin.
39
+ - import other required official tailwind plugins
40
+ - `@tailwindcss/forms`
41
+ - `@tailwindcss/typography`
42
+
43
+ in main.ts file
44
+
45
+ ```js
46
+ import { createApp } from 'vue';
47
+ import { EltyVuePlugin } from '@davincihealthcare/elty-design-system-vue';
48
+
49
+ ...
50
+
51
+ const app = createApp();
52
+ app.use(EltyVuePlugin);
53
+
54
+
55
+ ...
56
+ ```
57
+
58
+ remember to `use` the related vue plugin (it will install form validation rules)!
59
+
29
60
  ```js
30
61
  // Import the component you need
31
62
  import { ElButton } from '@davincihealthcare/elty-design-system-vue';
@@ -36,16 +67,14 @@ Now, you can use the imported component in your templates:
36
67
  ```vue
37
68
  <template>
38
69
  <div>
39
- <ElButton @click="handleClick">Click me</Button>
70
+ <ElButton label="Click me" @click="onClick" />
40
71
  </div>
41
72
  </template>
42
73
 
43
74
  <script lang="ts" setup>
44
-
45
- const handleClick = () => {
46
- // Handle button click
47
- }
48
-
75
+ import { ElButton } from '@davincihealthcare/elty-design-system-vue';
76
+ const onClick = () => {
77
+ window.alert('click');
78
+ };
49
79
  </script>
50
-
51
80
  ```
@@ -1 +1 @@
1
- export {};
1
+ export declare const defineValidationRules: () => void;
package/dist/index.d.ts CHANGED
@@ -1,4 +1,5 @@
1
- export { default as EltyPlugin } from './elty.plugin';
1
+ export { default as EltyVuePlugin } from './vue.plugin';
2
+ export { default as EltyTailwindPlugin } from './tailwind.plugin';
2
3
  export * from './routes';
3
4
  export * from './types';
4
5
  export * from './ElAccordion.vue';