@policystudio/policy-studio-ui-vue 1.1.90-beta.5 → 1.1.90-beta.50

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 (160) hide show
  1. package/.eslintrc.js +2 -8
  2. package/.github/workflows/deploy-storybook.yml +4 -4
  3. package/.nvmrc +1 -0
  4. package/dist/css/psui_styles_output.css +6639 -0
  5. package/dist/index.d.ts +51 -0
  6. package/dist/index.js +106 -0
  7. package/dist/index.js.map +1 -0
  8. package/dist/util/GeneralFunctions.d.ts +3 -0
  9. package/dist/util/GeneralFunctions.js +35 -0
  10. package/dist/util/GeneralFunctions.js.map +1 -0
  11. package/dist/util/directives.d.ts +1 -0
  12. package/dist/util/directives.js +22 -0
  13. package/dist/util/directives.js.map +1 -0
  14. package/dist/util/imageLoader.d.ts +6 -0
  15. package/dist/util/imageLoader.js +52 -0
  16. package/dist/util/imageLoader.js.map +1 -0
  17. package/doc/.nvmrc +1 -0
  18. package/{.storybook → doc/.storybook}/main.ts +8 -2
  19. package/{.storybook → doc/.storybook}/preview.ts +2 -3
  20. package/doc/package-lock.json +22653 -0
  21. package/doc/package.json +71 -0
  22. package/{src → doc}/shims-vue.d.ts +0 -5
  23. package/{src → doc/src}/stories/Accordion.stories.ts +2 -3
  24. package/{src → doc/src}/stories/BadgeWithIcon.stories.ts +1 -1
  25. package/{src → doc/src}/stories/BarChart.stories.ts +1 -1
  26. package/{src → doc/src}/stories/Breadcrumb.stories.ts +1 -1
  27. package/doc/src/stories/Button.stories.ts +130 -0
  28. package/{src → doc/src}/stories/CardInfos.stories.ts +1 -1
  29. package/{src → doc/src}/stories/ChartLegend.stories.ts +1 -1
  30. package/{src → doc/src}/stories/Checkbox.stories.ts +1 -1
  31. package/{src → doc/src}/stories/CheckboxSimple.stories.ts +1 -1
  32. package/{src → doc/src}/stories/Chips.stories.ts +1 -4
  33. package/{src → doc/src}/stories/ClimateZoneBadge.stories.ts +2 -1
  34. package/doc/src/stories/Collapse.stories.ts +46 -0
  35. package/{src → doc/src}/stories/CostEffectBar.stories.ts +2 -1
  36. package/{src → doc/src}/stories/Datatable.stories.ts +5 -2
  37. package/{src → doc/src}/stories/DateCardInfo.stories.ts +1 -1
  38. package/{src → doc/src}/stories/Dialog.stories.ts +2 -2
  39. package/{src → doc/src}/stories/Draggable.stories.ts +3 -2
  40. package/{src → doc/src}/stories/Dropdown.stories.ts +4 -3
  41. package/{src → doc/src}/stories/DropdownList.stories.ts +4 -2
  42. package/{src → doc/src}/stories/HighlightRippleDot.stories.ts +3 -2
  43. package/{src → doc/src}/stories/Icon.stories.ts +3 -1
  44. package/{src → doc/src}/stories/InlineSelector.stories.ts +1 -1
  45. package/{src → doc/src}/stories/Input.stories.ts +7 -4
  46. package/{src → doc/src}/stories/InputSelect.stories.ts +3 -2
  47. package/{src → doc/src}/stories/InputTextArea.stories.ts +1 -1
  48. package/{src → doc/src}/stories/MiniTag.stories.ts +9 -2
  49. package/{src → doc/src}/stories/ProgressBar.stories.ts +3 -2
  50. package/{src → doc/src}/stories/RadioButton.stories.ts +2 -2
  51. package/{src → doc/src}/stories/RadioButtonSimple.stories.ts +1 -1
  52. package/{src → doc/src}/stories/SimpleAlert.stories.ts +3 -2
  53. package/{src → doc/src}/stories/Slider.stories.ts +6 -2
  54. package/{src → doc/src}/stories/Switch.stories.ts +2 -2
  55. package/{src → doc/src}/stories/TabHeader.stories.ts +6 -1
  56. package/{src → doc/src}/stories/TableResults.stories.ts +11 -7
  57. package/{src → doc/src}/stories/TagScope.stories.ts +3 -2
  58. package/{src → doc/src}/stories/TestimonialCard.stories.ts +3 -3
  59. package/{src → doc/src}/stories/Toast.stories.ts +2 -2
  60. package/{src → doc/src}/stories/Toggle.stories.ts +6 -3
  61. package/{src → doc/src}/stories/Tooltip.stories.ts +3 -3
  62. package/doc/tsconfig.json +17 -0
  63. package/package.json +13 -28
  64. package/scripts/gulp.js +11 -0
  65. package/src/assets/scss/base.scss +3 -34
  66. package/src/assets/scss/components/PsAccordion.scss +1 -1
  67. package/src/assets/scss/components/PsChips.scss +9 -3
  68. package/src/assets/scss/components/PsCollapse.scss +71 -0
  69. package/src/assets/scss/components/PsDataTable.scss +1 -1
  70. package/src/assets/scss/components/PsDropdownList.scss +1 -1
  71. package/src/assets/scss/components/PsTableResults.scss +28 -1
  72. package/src/assets/scss/components/PsTooltip.scss +2 -1
  73. package/src/components/accordion/PsAccordionItem.vue +88 -74
  74. package/src/components/badges-and-tags/PsBadgeWithIcon.vue +31 -34
  75. package/src/components/badges-and-tags/PsCardInfos.vue +39 -41
  76. package/src/components/badges-and-tags/PsChartLegend.vue +46 -51
  77. package/src/components/badges-and-tags/PsClimateZoneBadge.vue +13 -19
  78. package/src/components/badges-and-tags/PsCostEffectBar.vue +24 -56
  79. package/src/components/badges-and-tags/PsDateCardInfo.vue +17 -18
  80. package/src/components/badges-and-tags/PsHighlightRippleDot.vue +3 -2
  81. package/src/components/badges-and-tags/PsMiniTag.vue +39 -41
  82. package/src/components/badges-and-tags/PsProgressBar.vue +72 -68
  83. package/src/components/badges-and-tags/PsTagScope.vue +17 -22
  84. package/src/components/badges-and-tags/PsTestimonialCard.vue +19 -26
  85. package/src/components/buttons/PsButton.vue +61 -62
  86. package/src/components/chips/PsChips.vue +112 -101
  87. package/src/components/collapse/PsCollapse.vue +124 -0
  88. package/src/components/controls/PsCheckbox.vue +84 -84
  89. package/src/components/controls/PsCheckboxSimple.vue +95 -95
  90. package/src/components/controls/PsDraggable.vue +53 -55
  91. package/src/components/controls/PsInlineSelector.vue +98 -99
  92. package/src/components/controls/PsRadioButton.vue +65 -58
  93. package/src/components/controls/PsRadioButtonSimple.vue +79 -75
  94. package/src/components/controls/PsSlider.vue +185 -176
  95. package/src/components/controls/PsSwitch.vue +51 -52
  96. package/src/components/controls/PsToggle.vue +52 -50
  97. package/src/components/data-graphics/PsBarChart.vue +18 -21
  98. package/src/components/datatable/PsDataTable.vue +56 -60
  99. package/src/components/datatable/PsDataTableItem.vue +13 -28
  100. package/src/components/forms/PsDropdown.vue +166 -162
  101. package/src/components/forms/PsDropdownList.vue +133 -130
  102. package/src/components/forms/PsInput.vue +154 -153
  103. package/src/components/forms/PsInputSelect.vue +91 -92
  104. package/src/components/forms/PsInputTextArea.vue +70 -71
  105. package/src/components/navigations/PsBreadcrumb.vue +25 -34
  106. package/src/components/notifications/PsDialog.vue +57 -56
  107. package/src/components/notifications/PsSimpleAlert.vue +27 -29
  108. package/src/components/notifications/PsToast.vue +40 -39
  109. package/src/components/table-results/PsTableResults.vue +461 -468
  110. package/src/components/table-results/PsTableResultsBody.vue +66 -67
  111. package/src/components/table-results/PsTableResultsHead.vue +70 -67
  112. package/src/components/table-results/PsTableResultsHeadComparison.vue +67 -64
  113. package/src/components/table-results/PsTableResultsHeadFlexible.vue +94 -67
  114. package/src/components/table-results/PsTableResultsRow.vue +55 -56
  115. package/src/components/tabs/PsTabHeader.vue +106 -100
  116. package/src/components/tooltip/PsDialogTooltip.vue +96 -101
  117. package/src/components/tooltip/PsRichTooltip.vue +41 -45
  118. package/src/components/tooltip/PsTooltip.vue +111 -116
  119. package/src/components/ui/PsDotLoader.vue +1 -5
  120. package/src/components/ui/PsIcon.vue +143 -132
  121. package/src/index.ts +60 -67
  122. package/src/tsconfig.json +12 -0
  123. package/src/types/index.d.ts +6 -0
  124. package/src/util/{GeneralFunctions.ts → GeneralFunctions.js} +12 -3
  125. package/src/util/directives.ts +24 -0
  126. package/src/util/{imageLoader.ts → imageLoader.js} +7 -0
  127. package/tailwind.config.js +1 -1
  128. package/tsconfig.json +18 -13
  129. package/.storybook/eventBus.ts +0 -26
  130. package/babel.config.js +0 -17
  131. package/dist/css/psui_styles.css +0 -4647
  132. package/postcss.config.js +0 -8
  133. package/src/components/playground/PsScrollBar.vue +0 -320
  134. package/src/stories/Button.stories.ts +0 -48
  135. package/src/stories/Button.vue +0 -59
  136. package/src/stories/Header.stories.ts +0 -41
  137. package/src/stories/Header.vue +0 -77
  138. package/src/stories/Playground.stories.ts +0 -16
  139. package/src/stories/button.css +0 -30
  140. package/src/stories/header.css +0 -32
  141. package/webpack.config.js +0 -22
  142. /package/{.storybook → doc/.storybook}/PolicyStudio.ts +0 -0
  143. /package/{.storybook → doc/.storybook}/manager.ts +0 -0
  144. /package/{src → doc/src}/assets/images/multifamily-units.svg +0 -0
  145. /package/{src → doc/src}/assets/images/policy-studio.svg +0 -0
  146. /package/{src → doc/src}/contents/ComparisonData.ts +0 -0
  147. /package/{src → doc/src}/contents/FlexibleData.ts +0 -0
  148. /package/{src → doc/src}/contents/ResultsData.ts +0 -0
  149. /package/{src → doc/src}/stories/Colors.mdx +0 -0
  150. /package/{src → doc/src}/stories/ElevationSystem.mdx +0 -0
  151. /package/{src → doc/src}/stories/Introduction.mdx +0 -0
  152. /package/{src → doc/src}/stories/Typography.mdx +0 -0
  153. /package/{src → doc/src}/stories/assets/code-brackets.svg +0 -0
  154. /package/{src → doc/src}/stories/assets/colors.svg +0 -0
  155. /package/{src → doc/src}/stories/assets/comments.svg +0 -0
  156. /package/{src → doc/src}/stories/assets/direction.svg +0 -0
  157. /package/{src → doc/src}/stories/assets/flow.svg +0 -0
  158. /package/{src → doc/src}/stories/assets/plugin.svg +0 -0
  159. /package/{src → doc/src}/stories/assets/repo.svg +0 -0
  160. /package/{src → doc/src}/stories/assets/stackalt.svg +0 -0
@@ -1,6 +1,8 @@
1
+
1
2
  import PsMiniTag, {
3
+ // @ts-ignore
2
4
  typeOptions,
3
- } from '../components/badges-and-tags/PsMiniTag.vue'
5
+ } from '../../../src/components/badges-and-tags/PsMiniTag.vue'
4
6
 
5
7
  export default {
6
8
  title: 'Badges & Tags/Tags/Mini Tag',
@@ -14,7 +16,7 @@ export default {
14
16
  },
15
17
  },
16
18
  }
17
-
19
+ // @ts-ignore
18
20
  const Template = (args, { argTypes }) => ({
19
21
  props: Object.keys(argTypes),
20
22
  components: { PsMiniTag },
@@ -22,30 +24,35 @@ const Template = (args, { argTypes }) => ({
22
24
  })
23
25
 
24
26
  export const Info = Template.bind({})
27
+ // @ts-ignore
25
28
  Info.args = {
26
29
  layout: 'info',
27
30
  message: 'This is an info alert',
28
31
  }
29
32
 
30
33
  export const Success = Template.bind({})
34
+ // @ts-ignore
31
35
  Success.args = {
32
36
  layout: 'success',
33
37
  message: 'This is a success alert',
34
38
  }
35
39
 
36
40
  export const Warning = Template.bind({})
41
+ // @ts-ignore
37
42
  Warning.args = {
38
43
  layout: 'warning',
39
44
  message: 'This is a warning alert',
40
45
  }
41
46
 
42
47
  export const Error = Template.bind({})
48
+ // @ts-ignore
43
49
  Error.args = {
44
50
  layout: 'error',
45
51
  message: 'This is an error alert',
46
52
  }
47
53
 
48
54
  export const Default = Template.bind({})
55
+ // @ts-ignore
49
56
  Default.args = {
50
57
  layout: 'default',
51
58
  message: 'This is a default color',
@@ -1,4 +1,4 @@
1
- import PsProgressBar from '../components/badges-and-tags/PsProgressBar.vue'
1
+ import PsProgressBar from '../../../src/components/badges-and-tags/PsProgressBar.vue'
2
2
 
3
3
  export default {
4
4
  title: 'Badges & Tags/Badges/ProgressBar',
@@ -12,7 +12,7 @@ export default {
12
12
  },
13
13
  },
14
14
  }
15
-
15
+ // @ts-ignore
16
16
  const TemplateDefault = (args, { argTypes }) => ({
17
17
  props: Object.keys(argTypes),
18
18
  components: { PsProgressBar },
@@ -20,4 +20,5 @@ const TemplateDefault = (args, { argTypes }) => ({
20
20
  })
21
21
 
22
22
  export const Default = TemplateDefault.bind({})
23
+ // @ts-ignore
23
24
  Default.args = {}
@@ -1,10 +1,10 @@
1
- import PsRadioButton from '../components/controls/PsRadioButton.vue'
1
+ import PsRadioButton from '../../../src/components/controls/PsRadioButton.vue'
2
2
 
3
3
  export default {
4
4
  title: 'Controls & Selectors/Radio Button',
5
5
  component: PsRadioButton,
6
6
  }
7
-
7
+ // @ts-ignore
8
8
  const DefaultTemplate = (args,{ argTypes}) => ({
9
9
  props: Object.keys(argTypes),
10
10
  components: { PsRadioButton},
@@ -1,4 +1,4 @@
1
- import PsRadioButtonSimple from '../components/controls/PsRadioButtonSimple.vue'
1
+ import PsRadioButtonSimple from '../../../src/components/controls/PsRadioButtonSimple.vue'
2
2
 
3
3
  export default {
4
4
  title: 'Text fields & Forms/Inputs V2/RadioButton',
@@ -1,10 +1,10 @@
1
- import PsSimpleAlert from '../components/notifications/PsSimpleAlert.vue'
1
+ import PsSimpleAlert from '../../../src/components/notifications/PsSimpleAlert.vue'
2
2
 
3
3
  export default {
4
4
  title: 'Notifications/Simple Alert',
5
5
  component: PsSimpleAlert,
6
6
  }
7
-
7
+ // @ts-ignore
8
8
  const TemplateDefault = (args, { argTypes }) => ({
9
9
  props: Object.keys(argTypes),
10
10
  components: { PsSimpleAlert },
@@ -16,6 +16,7 @@ export default {
16
16
  })
17
17
 
18
18
  export const Default = TemplateDefault.bind({})
19
+ // @ts-ignore
19
20
  Default.args = {
20
21
  message:'lorem'
21
22
  }
@@ -1,4 +1,4 @@
1
- import PsSlider from '../components/controls/PsSlider.vue'
1
+ import PsSlider from '../../../src/components/controls/PsSlider.vue'
2
2
 
3
3
  export default {
4
4
  title: 'Text fields & Forms/Slider',
@@ -7,7 +7,7 @@ export default {
7
7
  // layout: { control: { type: 'inline-radio', options: sliderLayout } },
8
8
  // },
9
9
  }
10
-
10
+ // @ts-ignore
11
11
  const Template = (args, { argTypes }) => ({
12
12
  props: Object.keys(argTypes),
13
13
  components: { PsSlider },
@@ -29,6 +29,7 @@ const Template = (args, { argTypes }) => ({
29
29
  })
30
30
 
31
31
  export const Label = Template.bind({})
32
+ // @ts-ignore
32
33
  Label.args = {
33
34
  min: 0,
34
35
  max: 200,
@@ -39,6 +40,7 @@ Label.args = {
39
40
  }
40
41
 
41
42
  export const NoLabel = Template.bind({})
43
+ // @ts-ignore
42
44
  NoLabel.args = {
43
45
  min: 0,
44
46
  max: 200,
@@ -48,6 +50,7 @@ NoLabel.args = {
48
50
  }
49
51
 
50
52
  export const Bubble = Template.bind({})
53
+ // @ts-ignore
51
54
  Bubble.args = {
52
55
  min: 0,
53
56
  max: 200,
@@ -62,6 +65,7 @@ const sliderColors = [
62
65
  { start: 170, end: 200, bgColor: '#D65C5A' },
63
66
  ]
64
67
  export const Rich = Template.bind({})
68
+ // @ts-ignore
65
69
  Rich.args = {
66
70
  min: 0,
67
71
  max: 200,
@@ -1,9 +1,9 @@
1
- import PsSwitch from '../components/controls/PsSwitch.vue'
1
+ import PsSwitch from '../../../src/components/controls/PsSwitch.vue'
2
2
  export default {
3
3
  title: 'Controls & Selectors/Switch',
4
4
  component: PsSwitch,
5
5
  }
6
-
6
+ // @ts-ignore
7
7
  const Template = (args, { argTypes }) => ({
8
8
  props: Object.keys(argTypes),
9
9
  components: { PsSwitch },
@@ -1,4 +1,4 @@
1
- import PsTabHeader from '../components/tabs/PsTabHeader.vue'
1
+ import PsTabHeader from '../../../src/components/tabs/PsTabHeader.vue'
2
2
  const items = ['Existing Buildings', 'New Constructions', 'Other tab']
3
3
  const item = items[0]
4
4
 
@@ -7,6 +7,8 @@ export default {
7
7
  component: PsTabHeader,
8
8
  argTypes: {}
9
9
  }
10
+
11
+ // @ts-ignore
10
12
  const Template = (args, { argTypes }) => ({
11
13
  props: Object.keys(argTypes),
12
14
  components: { PsTabHeader },
@@ -31,6 +33,7 @@ const Template = (args, { argTypes }) => ({
31
33
  })
32
34
 
33
35
  export const Standard = Template.bind({})
36
+ // @ts-ignore
34
37
  Standard.args = {
35
38
  layout: 'standard',
36
39
  items: items,
@@ -38,6 +41,7 @@ Standard.args = {
38
41
  }
39
42
 
40
43
  export const Underline = Template.bind({})
44
+ // @ts-ignore
41
45
  Underline.args = {
42
46
  layout: 'underline',
43
47
  items: items,
@@ -45,6 +49,7 @@ Underline.args = {
45
49
  }
46
50
 
47
51
  export const Folder = Template.bind({})
52
+ // @ts-ignore
48
53
  Folder.args = {
49
54
  layout: 'folder',
50
55
  items: items,
@@ -1,9 +1,10 @@
1
- import PsTableResults, { tableLayout } from '../components/table-results/PsTableResults.vue'
2
- import PsTableResultsHead from '../components/table-results/PsTableResultsHead.vue'
3
- import PsTableResultsHeadFlexible from '../components/table-results/PsTableResultsHeadFlexible.vue'
4
- import PsTableResultsHeadComparison from '../components/table-results/PsTableResultsHeadComparison.vue'
5
- import PsProgressBar from '../components/badges-and-tags/PsProgressBar.vue'
6
- import PsSwitch from '../components/controls/PsSwitch.vue'
1
+ // @ts-ignore
2
+ import PsTableResults, { tableLayout } from '../../../src/components/table-results/PsTableResults.vue'
3
+ import PsTableResultsHead from '../../../src/components/table-results/PsTableResultsHead.vue'
4
+ import PsTableResultsHeadFlexible from '../../../src/components/table-results/PsTableResultsHeadFlexible.vue'
5
+ import PsTableResultsHeadComparison from '../../../src/components/table-results/PsTableResultsHeadComparison.vue'
6
+ import PsProgressBar from '../../../src/components/badges-and-tags/PsProgressBar.vue'
7
+ import PsSwitch from '../../../src/components/controls/PsSwitch.vue'
7
8
 
8
9
  import { resultsDataHeader, resultsDataColumnGroup, resultsDataSummary } from '../contents/ResultsData'
9
10
  import { comparisonDataHeader, comparisonDataColumnGroup, comparisonDataSummary } from '../contents/ComparisonData'
@@ -18,7 +19,7 @@ export default {
18
19
  onCollapse: { action: 'clicked' },
19
20
  },
20
21
  }
21
-
22
+ // @ts-ignore
22
23
  const TableResults = (args, { argTypes }) => ({
23
24
  props: Object.keys(argTypes),
24
25
  components: { PsTableResults, PsTableResultsHead, PsTableResultsHeadComparison, PsTableResultsHeadFlexible },
@@ -54,6 +55,7 @@ const TableResults = (args, { argTypes }) => ({
54
55
  })
55
56
 
56
57
  export const Results = TableResults.bind({})
58
+ // @ts-ignore
57
59
  Results.args = {
58
60
  layout: 'results',
59
61
  header: resultsDataHeader,
@@ -64,6 +66,7 @@ Results.args = {
64
66
  }
65
67
 
66
68
  export const Comparison = TableResults.bind({})
69
+ // @ts-ignore
67
70
  Comparison.args = {
68
71
  layout: 'comparison',
69
72
  header: comparisonDataHeader,
@@ -74,6 +77,7 @@ Comparison.args = {
74
77
  }
75
78
 
76
79
  export const Flexible = TableResults.bind({})
80
+ // @ts-ignore
77
81
  Flexible.args = {
78
82
  layout: 'flexible',
79
83
  header: flexibleDataHeader,
@@ -1,9 +1,10 @@
1
- import PsTagScope from '../components/badges-and-tags/PsTagScope.vue'
1
+ import PsTagScope from '../../../src/components/badges-and-tags/PsTagScope.vue'
2
+
2
3
  export default {
3
4
  title: 'Badges & Tags/Tags/Tag Scope',
4
5
  component: PsTagScope,
5
6
  }
6
-
7
+ // @ts-ignore
7
8
  const defaultTemplate = (args, {argTypes}) => ({
8
9
  props: Object.keys(argTypes),
9
10
  components: { PsTagScope },
@@ -1,10 +1,10 @@
1
- import PsTestimonialCard from '../components/badges-and-tags/PsTestimonialCard.vue'
1
+ import PsTestimonialCard from '../../../src/components/badges-and-tags/PsTestimonialCard.vue'
2
2
 
3
3
  export default {
4
4
  title: 'Components/TestimonialCard',
5
5
  component: PsTestimonialCard,
6
6
  }
7
-
7
+ // @ts-ignore
8
8
  const Template = (args,{argTypes}) => ({
9
9
  props: Object.keys(argTypes),
10
10
  components:{PsTestimonialCard},
@@ -18,7 +18,7 @@ export default {
18
18
  })
19
19
 
20
20
  export const Default = Template.bind({})
21
-
21
+ // @ts-ignore
22
22
  Default.args = {
23
23
  testimonial: 'I used to spend most of my time helping California cities make reach codes. Now, i just show them the Explorer and get to focus on helping cities in other states.',
24
24
  user:'Amy Rider',
@@ -1,9 +1,9 @@
1
- import PsToast from '../components/notifications/PsToast.vue'
1
+ import PsToast from '../../../src/components/notifications/PsToast.vue'
2
2
  export default {
3
3
  title: 'Notifications/Toast',
4
4
  component: PsToast,
5
5
  }
6
-
6
+ // @ts-ignore
7
7
  const Template = (args, { argTypes }) => ({
8
8
  props: Object.keys(argTypes),
9
9
  components: { PsToast },
@@ -1,4 +1,4 @@
1
- import PsToggle from '../components/controls/PsToggle.vue'
1
+ import PsToggle from '../../../src/components/controls/PsToggle.vue'
2
2
  export default {
3
3
  title: 'Components/Toggle',
4
4
  component: PsToggle,
@@ -6,7 +6,7 @@ export default {
6
6
  }
7
7
  const items = ['Option 1', 'Option 2', 'Option 3']
8
8
  const selected = 'Option 2'
9
-
9
+ // @ts-ignore
10
10
  const Template = (args, { argTypes }) => ({
11
11
  props: Object.keys(argTypes),
12
12
  components: { PsToggle },
@@ -16,6 +16,7 @@ const Template = (args, { argTypes }) => ({
16
16
  })
17
17
 
18
18
  export const Default = Template.bind({})
19
+ // @ts-ignore
19
20
  Default.args = {
20
21
  items: items,
21
22
  selected: selected,
@@ -28,11 +29,13 @@ Default.args = {
28
29
  * Se quiser dar uma melhorada nessa parte, fique a vontade meu chegado! TMJ
29
30
  */
30
31
  window.addEventListener('click', (ev) => {
32
+ // @ts-ignore
31
33
  if (ev.target.classList.contains('click-to-copy')) {
34
+ // @ts-ignore
32
35
  copyText(ev.target.dataset.toCopy)
33
36
  }
34
37
  })
35
-
38
+ // @ts-ignore
36
39
  function copyText(textToCopy) {
37
40
  const myTemporaryInputElement = document.createElement('input')
38
41
  myTemporaryInputElement.type = 'text'
@@ -1,6 +1,6 @@
1
- import PsTooltip from '../components/tooltip/PsTooltip.vue'
2
- import PsRichTooltip from '../components/tooltip/PsRichTooltip.vue'
3
- import PsDialogTooltip from '../components/tooltip/PsDialogTooltip.vue'
1
+ import PsTooltip from '../../../src/components/tooltip/PsTooltip.vue'
2
+ import PsRichTooltip from '../../../src/components/tooltip/PsRichTooltip.vue'
3
+ import PsDialogTooltip from '../../../src/components/tooltip/PsDialogTooltip.vue'
4
4
 
5
5
  export default {
6
6
  title: 'Components/Tooltip',
@@ -0,0 +1,17 @@
1
+ {
2
+ "compilerOptions": {
3
+ "rootDir": "../",
4
+ "strict": true,
5
+ "outDir": "../dist",
6
+ },
7
+ "include": [
8
+ "doc/src/**/*.ts",
9
+ "doc/.storybook/**/*.ts",
10
+ "doc/src/**/*.stories.ts",
11
+ "doc/*.d.ts",
12
+ ],
13
+ "references": [
14
+ {"path": "../"}
15
+ ]
16
+ }
17
+
package/package.json CHANGED
@@ -1,22 +1,19 @@
1
1
  {
2
2
  "name": "@policystudio/policy-studio-ui-vue",
3
- "version": "1.1.90-beta.5",
3
+ "version": "1.1.90-beta.50",
4
4
  "description": "Policy Studio UI",
5
5
  "author": "Policy Studio Team",
6
6
  "scripts": {
7
- "serve": "concurrently --kill-others \"npm run watch-storybook\" \"npm run watch-tailwind\"",
8
7
  "lint": "vue-cli-service lint",
9
- "build-storybook": "storybook build",
10
- "build-tailwind": "postcss src/assets/scss/base.scss -o dist/css/psui_styles.css",
11
- "build-temp-tailwind": "postcss src/assets/scss/base.scss -o temp/css/psui_styles.css",
12
- "full-publish": "npm run lint && npm run build-tailwind && npm run build-storybook && npm publish --tag beta",
8
+ "build": "tsc -p tsconfig.json && npm run build:tailwind && npm run gulp",
9
+ "full-publish": "npm run lint && npm run build && npm publish --tag beta",
13
10
  "kill-port": "sh ./scripts/kill-port.sh",
14
- "serve-prod": "concurrently --kill-others \"npm run watch-storybook\" \"npm run watch-prod-tailwind\"",
15
- "storybook": "concurrently \"npm run kill-port\" \"npm run watch-prod-tailwind\" \"storybook dev -p 6006\"",
16
- "watch-prod-tailwind": "watch 'npm run build-tailwind' ./src/assets",
17
- "watch-tailwind": "watch 'npm run build-temp-tailwind' ./src/assets"
11
+ "build:tailwind": "tailwindcss build -i src/assets/scss/base.scss -o dist/css/psui_styles_output.css -c tailwind.config.js",
12
+ "watch:tailwind": "watch 'npm run build:tailwind' dist/css",
13
+ "gulp": "gulp --gulpfile scripts/gulp.js build"
18
14
  },
19
- "main": "src/index.js",
15
+ "main": "dist/index.js",
16
+ "types": "src/types/index.d.ts",
20
17
  "dependencies": {
21
18
  "@vue/compat": "^3.4.5",
22
19
  "core-js": "^3.6.5",
@@ -24,17 +21,6 @@
24
21
  "vue": "^3.4.5"
25
22
  },
26
23
  "devDependencies": {
27
- "@babel/cli": "^7.23.4",
28
- "@babel/core": "^7.23.7",
29
- "@babel/eslint-parser": "^7.23.3",
30
- "@babel/preset-env": "^7.23.7",
31
- "@storybook/addon-essentials": "^7.6.7",
32
- "@storybook/addon-interactions": "^7.6.7",
33
- "@storybook/addon-links": "^7.6.7",
34
- "@storybook/blocks": "^7.6.7",
35
- "@storybook/test": "^7.6.7",
36
- "@storybook/vue3": "^7.6.7",
37
- "@storybook/vue3-webpack5": "^7.6.7",
38
24
  "@typescript-eslint/eslint-plugin": "^5.4.0",
39
25
  "@typescript-eslint/parser": "^5.4.0",
40
26
  "@vue/cli-plugin-eslint": "^5.0.8",
@@ -43,21 +29,20 @@
43
29
  "@vue/compiler-sfc": "^3.4.5",
44
30
  "@vue/eslint-config-prettier": "^9.0.0",
45
31
  "@vue/eslint-config-typescript": "^9.1.0",
46
- "babel-eslint": "^10.1.0",
47
32
  "concurrently": "^7.0.0",
48
33
  "eslint": "^8.56.0",
49
34
  "eslint-plugin-prettier": "^5.1.2",
50
- "eslint-plugin-storybook": "^0.6.15",
51
35
  "eslint-plugin-vue": "^8.7.1",
36
+ "gulp": "^5.0.0",
37
+ "gulp-sass": "^5.1.0",
52
38
  "postcss": "^8.3.11",
53
39
  "postcss-cli": "^9.0.2",
54
40
  "postcss-import": "^14.0.2",
55
41
  "postcss-nested": "^5.0.6",
56
42
  "prettier": "^3.1.1",
57
- "react": "^18.2.0",
58
- "react-dom": "^18.2.0",
59
- "storybook": "^7.6.7",
43
+ "sass": "^1.77.1",
60
44
  "tailwindcss": "^3.4.1",
45
+ "ts-loader": "^9.5.1",
61
46
  "typescript": "~4.5.5",
62
47
  "vue-eslint-parser": "^9.3.2",
63
48
  "vue-loader": "^17.4.2",
@@ -65,7 +50,7 @@
65
50
  "webpack": "^5.89.0"
66
51
  },
67
52
  "engines": {
68
- "node": "18.19.0"
53
+ "node": "20.11.0"
69
54
  },
70
55
  "keywords": [
71
56
  "vue",
@@ -0,0 +1,11 @@
1
+ const gulp = require('gulp')
2
+ const sass = require('gulp-sass')(require('sass'))
3
+
4
+ gulp.task('build', () => {
5
+
6
+ return gulp.src([
7
+ '../dist/css/psui_styles_output.css'
8
+ ])
9
+ .pipe(sass().on('error',sass.logError))
10
+ .pipe(gulp.dest('../dist/css'))
11
+ })
@@ -35,6 +35,9 @@
35
35
  @import './components/PsBarChart.scss';
36
36
  @import './components/PsSimpleAlert.scss';
37
37
  @import './components/PsBreadcrumb.scss';
38
+ @import './components/PsCollapse.scss';
39
+
40
+
38
41
  @import "tailwindcss/base";
39
42
  @import "tailwindcss/components";
40
43
  @import "tailwindcss/utilities";
@@ -68,38 +71,4 @@ html {
68
71
  }
69
72
 
70
73
 
71
- @layer components {
72
- .psui-card {
73
- @apply .psui-w-full .psui-bg-white .psui-rounded-lg .psui-px-6 .psui-py-4 .psui-shadow-elevation-5;
74
-
75
- &-header {
76
- @apply .psui-flex .psui-items-center .psui-justify-between .psui-mb-4;
77
-
78
- h4 {
79
- @apply .psui-text-h6 .psui-font-bold .psui-text-gray-80;
80
- }
81
- }
82
- }
83
-
84
- .psui-show-childrens-on-hover {
85
- &:hover {
86
- * {
87
- opacity: 1 !important;
88
- }
89
- }
90
-
91
- &.absolute-childrens {
92
- @apply psui-relative;
93
-
94
- .helper {
95
- @apply psui-absolute psui-top-0;
96
- right: -18px;
97
- }
98
- }
99
- }
100
-
101
- .psui-transition {
102
- @apply psui-transition-all psui-ease-in-out psui-duration-150;
103
- }
104
- }
105
74
 
@@ -101,7 +101,7 @@
101
101
  overflow: hidden;
102
102
  }
103
103
 
104
- .accordion-fade-enter,
104
+ .accordion-fade-enter-from,
105
105
  .accordion-fade-leave-to {
106
106
  height: 0 !important;
107
107
  margin-bottom: 0 !important;
@@ -19,7 +19,15 @@
19
19
  &:checked {
20
20
  + label {
21
21
  @apply psui-text-blue-60 psui-bg-blue-20;
22
-
22
+
23
+ &.layout-disabled {
24
+ @apply psui-bg-gray-20 psui-text-gray-40 psui-cursor-default;
25
+
26
+ &:before {
27
+ @apply psui-text-gray-30 psui-cursor-default;
28
+ }
29
+ }
30
+
23
31
  &:before {
24
32
  @apply psui-text-blue-50;
25
33
  }
@@ -82,8 +90,6 @@
82
90
  }
83
91
 
84
92
  &.type-button {
85
-
86
-
87
93
  label {
88
94
  @apply psui-flex psui-items-center psui-justify-center psui-text-gray-60 psui-transition-all psui-cursor-pointer psui-rounded psui-py-1 psui-px-3 psui-text-small;
89
95
  background-color: #F6F7F8;
@@ -0,0 +1,71 @@
1
+ @layer components {
2
+
3
+ .psui-el-collapse {
4
+
5
+ .psui-el-collapse-item-content {
6
+ @apply psui-relative psui-pl-4;
7
+
8
+ &::before {
9
+ @apply psui-bg-gray-30 psui-ml-2;
10
+ content: "";
11
+ position: absolute;
12
+ top: 0;
13
+ left: 0;
14
+ width: 1px;
15
+ height: 100%;
16
+ transform: translateX(-50%);
17
+ }
18
+ }
19
+
20
+
21
+
22
+ .psui-el-collapse-item-header {
23
+ @apply psui-flex psui-items-center psui-cursor-pointer;
24
+
25
+ .psui-el-collapse-item-icon {
26
+ @apply psui-text-gray-50 psui-transition-all;
27
+ transition-duration: 0.4s;
28
+ font-size: 16px;
29
+ }
30
+
31
+ .psui-el-collapse-item-header-wrapper {
32
+ @apply psui-flex psui-items-center psui-py-2 psui-text-small psui-w-full;
33
+
34
+ .psui-el-collapse-item-title {
35
+ @apply psui-ml-1 psui-text-gray-70 hover:psui-text-blue-60;
36
+
37
+ &.disabled {
38
+ @apply psui-text-gray-50;
39
+ }
40
+
41
+ }
42
+
43
+ .psui-el-collapse-item-header-action {
44
+ @apply psui-invisible psui-ml-auto psui-text-gray-70 hover:psui-text-blue-60;
45
+ }
46
+ }
47
+
48
+ &:hover {
49
+ .psui-el-collapse-item-header-wrapper {
50
+ .psui-el-collapse-item-header-action {
51
+ @apply psui-visible;
52
+ }
53
+ }
54
+ }
55
+ }
56
+
57
+
58
+ .collapse-fade-enter-active,
59
+ .collapse-fade-leave-active {
60
+ will-change: height, margin-bottom;
61
+ transition: height 0.4s ease-in-out, margin-bottom 0.4s ease-in-out;
62
+ overflow: hidden;
63
+ }
64
+
65
+ .collapse-fade-enter-from,
66
+ .collapse-fade-leave-to {
67
+ height: 0 !important;
68
+ margin-bottom: 0 !important;
69
+ }
70
+ }
71
+ }
@@ -58,7 +58,7 @@
58
58
  td,
59
59
  tr {
60
60
  padding: 7px 16px;
61
- @apply .psui-text-gray-80;
61
+ @apply psui-text-gray-80;
62
62
  }
63
63
  }
64
64
  }
@@ -3,7 +3,7 @@
3
3
  @apply psui-w-full psui-flex psui-flex-col psui-font-medium psui-my-4;
4
4
 
5
5
  .psui-el-dropdown-menu-list-item {
6
- @apply psui-flex psui-items-end psui-justify-between psui-mx-0 psui-text-small psui-text-gray-60 psui-cursor-pointer psui-transition-all psui-show-childrens-on-hover;
6
+ @apply psui-flex psui-items-end psui-justify-between psui-mx-0 psui-text-small psui-text-gray-60 psui-cursor-pointer psui-transition-all;
7
7
  padding: 7px 20px;
8
8
 
9
9
  &-left-label {