@pareto-engineering/design-system 4.0.0-alpha.76 → 4.0.0-alpha.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 (173) hide show
  1. package/dist/cjs/a/AnimatedBlobs/AnimatedBlobs.js +1 -1
  2. package/dist/cjs/a/AnimatedGradient/AnimatedGradient.js +1 -1
  3. package/dist/cjs/a/AppContext/Context.js +1 -1
  4. package/dist/cjs/a/AppContext/ContextProvider.js +1 -1
  5. package/dist/cjs/a/BlurOverlay/BlurOverlay.js +1 -1
  6. package/dist/cjs/a/ContentTree/ContentTree.js +1 -1
  7. package/dist/cjs/a/ContentTree/common/Tree/Tree.js +1 -1
  8. package/dist/cjs/a/Conversation/Context.js +1 -1
  9. package/dist/cjs/a/Conversation/Conversation.js +1 -1
  10. package/dist/cjs/a/Conversation/common/Message/Message.js +1 -1
  11. package/dist/cjs/a/DatePicker/DatePicker.js +1 -1
  12. package/dist/cjs/a/DotInfo/DotInfo.js +1 -1
  13. package/dist/cjs/a/Figure/Figure.js +1 -1
  14. package/dist/cjs/a/HamburgerButton/HamburgerButton.js +1 -1
  15. package/dist/cjs/a/IconList/IconList.js +1 -1
  16. package/dist/cjs/a/IconList/common/Item/Item.js +1 -1
  17. package/dist/cjs/a/Label/Label.js +1 -1
  18. package/dist/cjs/a/LexicalPreview/LexicalPreview.js +1 -1
  19. package/dist/cjs/a/LoadingCircle/LoadingCircle.js +1 -1
  20. package/dist/cjs/a/MetaCard/MetaCard.js +1 -1
  21. package/dist/cjs/a/People/People.js +1 -1
  22. package/dist/cjs/a/People/common/Person/Person.js +1 -1
  23. package/dist/cjs/a/People/styles.scss +1 -1
  24. package/dist/cjs/a/Popover/Popover.js +1 -1
  25. package/dist/cjs/a/ProgressBar/ProgressBar.js +1 -1
  26. package/dist/cjs/a/Quote/Quote.js +16 -6
  27. package/dist/cjs/a/Quote/styles.scss +16 -37
  28. package/dist/cjs/a/Removable/Removable.js +1 -1
  29. package/dist/cjs/a/SVG/SVG.js +1 -1
  30. package/dist/cjs/a/SVG/common/UseSVG/UseSVG.js +1 -1
  31. package/dist/cjs/a/SnapScroller/SnapScroller.js +1 -1
  32. package/dist/cjs/a/Spinner/Spinner.js +1 -1
  33. package/dist/cjs/a/TextSteps/TextSteps.js +1 -1
  34. package/dist/cjs/a/Timestamp/Timestamp.js +1 -1
  35. package/dist/cjs/a/Tip/Tip.js +1 -1
  36. package/dist/cjs/a/ToggleSwitch/ToggleSwitch.js +1 -1
  37. package/dist/cjs/a/Tooltip/Tooltip.js +71 -0
  38. package/dist/cjs/a/Tooltip/index.js +13 -0
  39. package/dist/cjs/a/Tooltip/styles.scss +53 -0
  40. package/dist/cjs/a/XMLEditor/XMLEditor.js +1 -1
  41. package/dist/cjs/a/index.js +8 -1
  42. package/dist/cjs/b/Button/Button.js +1 -1
  43. package/dist/cjs/b/Button/common/Group/Group.js +1 -1
  44. package/dist/cjs/b/Card/Card.js +1 -1
  45. package/dist/cjs/b/Card/common/Group/Group.js +1 -1
  46. package/dist/cjs/b/Card/common/Section/Section.js +1 -1
  47. package/dist/cjs/b/ExpandableLexicalPreview/ExpandableLexicalPreview.js +3 -3
  48. package/dist/cjs/b/ExpandableLexicalPreview/common/ExpandButton/ExpandButton.js +3 -3
  49. package/dist/cjs/b/Logo/Logo.js +1 -1
  50. package/dist/cjs/b/Page/Context.js +1 -1
  51. package/dist/cjs/b/Page/Page.js +1 -1
  52. package/dist/cjs/b/Page/common/PageHelmet/PageHelmet.js +1 -1
  53. package/dist/cjs/b/Page/common/Section/Section.js +1 -1
  54. package/dist/cjs/b/SocialMediaButton/SocialMediaButton.js +1 -1
  55. package/dist/cjs/b/ThemeSelector/ThemeSelector.js +1 -1
  56. package/dist/cjs/b/Title/Title.js +1 -1
  57. package/dist/cjs/c/Modal/Modal.js +1 -1
  58. package/dist/cjs/c/Modal/common/ModalHeader/ModalHeader.js +1 -1
  59. package/dist/cjs/c/Shortener/Shortener.js +1 -1
  60. package/dist/cjs/c/SocialMediaShareButton/SocialMediaShareButton.js +1 -1
  61. package/dist/cjs/f/FormInput/FormInput.js +1 -1
  62. package/dist/cjs/f/common/Debugger/Debugger.js +1 -1
  63. package/dist/cjs/f/common/Description/Description.js +1 -1
  64. package/dist/cjs/f/common/Description/styles.scss +1 -2
  65. package/dist/cjs/f/common/Label/Label.js +1 -1
  66. package/dist/cjs/f/fields/Checkbox/Checkbox.js +1 -1
  67. package/dist/cjs/f/fields/ChoicesInput/ChoicesInput.js +1 -1
  68. package/dist/cjs/f/fields/ChoicesInput/common/Choice/Choice.js +1 -1
  69. package/dist/cjs/f/fields/EditorInput/EditorInput.js +20 -9
  70. package/dist/cjs/f/fields/EditorInput/common/BlockFormatDropDown/BlockFormatDropDown.js +256 -0
  71. package/dist/cjs/f/fields/EditorInput/common/BlockFormatDropDown/index.js +13 -0
  72. package/dist/cjs/f/fields/EditorInput/common/BlockFormatDropDown/styles.scss +55 -0
  73. package/dist/cjs/f/fields/EditorInput/common/ColorPicker/ColorPicker.js +94 -0
  74. package/dist/cjs/f/fields/EditorInput/common/ColorPicker/index.js +13 -0
  75. package/dist/cjs/f/fields/EditorInput/common/ColorPicker/styles.scss +36 -0
  76. package/dist/cjs/f/fields/EditorInput/common/FontSizeDropDown/FontSizeDropDown.js +94 -0
  77. package/dist/cjs/f/fields/EditorInput/common/FontSizeDropDown/index.js +13 -0
  78. package/dist/cjs/f/fields/EditorInput/common/FontSizeDropDown/styles.scss +55 -0
  79. package/dist/cjs/f/fields/EditorInput/common/ToolbarPlugin/ToolbarPlugin.js +295 -0
  80. package/dist/cjs/f/fields/EditorInput/common/ToolbarPlugin/index.js +13 -0
  81. package/dist/cjs/f/fields/EditorInput/common/ToolbarPlugin/styles.scss +56 -0
  82. package/dist/cjs/f/fields/EditorInput/common/index.js +24 -3
  83. package/dist/cjs/f/fields/EditorInput/styles.scss +109 -25
  84. package/dist/cjs/f/fields/LinkInput/LinkInput.js +1 -1
  85. package/dist/cjs/f/fields/QueryChoices/QueryChoices.js +1 -1
  86. package/dist/cjs/f/fields/QueryCombobox/QueryCombobox.js +1 -1
  87. package/dist/cjs/f/fields/QueryCombobox/common/Combobox/Combobox.js +1 -1
  88. package/dist/cjs/f/fields/QueryCombobox/common/Menu/Menu.js +1 -1
  89. package/dist/cjs/f/fields/QueryCombobox/common/MultipleCombobox/MultipleCombobox.js +1 -1
  90. package/dist/cjs/f/fields/QuerySelect/QuerySelect.js +1 -1
  91. package/dist/cjs/f/fields/RatingsInput/RatingsInput.js +1 -1
  92. package/dist/cjs/f/fields/RatingsInput/common/Rating/Rating.js +1 -1
  93. package/dist/cjs/f/fields/SelectInput/SelectInput.js +1 -1
  94. package/dist/cjs/f/fields/SelectInput/common/Menu/Menu.js +1 -1
  95. package/dist/cjs/f/fields/SelectInput/common/Multiple/Multiple.js +1 -1
  96. package/dist/cjs/f/fields/SelectInput/common/Single/Single.js +1 -1
  97. package/dist/cjs/f/fields/TextInput/TextInput.js +1 -1
  98. package/dist/cjs/f/fields/TextInput/styles.scss +5 -2
  99. package/dist/cjs/f/fields/TextareaInput/TextareaInput.js +1 -1
  100. package/dist/cjs/test/QueryLoader/QueryLoader.js +1 -1
  101. package/dist/cjs/test/QueryLoader/common/PreloadedTestData/PreloadedTestData.js +1 -1
  102. package/dist/cjs/utils/hooks/index.js +7 -0
  103. package/dist/cjs/utils/hooks/useOutsideClick.js +25 -0
  104. package/dist/cjs/utils/index.js +6 -0
  105. package/dist/es/a/People/styles.scss +1 -1
  106. package/dist/es/a/Quote/Quote.js +15 -5
  107. package/dist/es/a/Quote/styles.scss +16 -37
  108. package/dist/es/a/Tooltip/Tooltip.js +59 -0
  109. package/dist/es/a/Tooltip/index.js +2 -0
  110. package/dist/es/a/Tooltip/styles.scss +53 -0
  111. package/dist/es/a/index.js +2 -1
  112. package/dist/es/b/ExpandableLexicalPreview/ExpandableLexicalPreview.js +1 -1
  113. package/dist/es/b/ExpandableLexicalPreview/common/ExpandButton/ExpandButton.js +1 -1
  114. package/dist/es/f/common/Description/styles.scss +1 -2
  115. package/dist/es/f/fields/EditorInput/EditorInput.js +20 -9
  116. package/dist/es/f/fields/EditorInput/common/BlockFormatDropDown/BlockFormatDropDown.js +246 -0
  117. package/dist/es/f/fields/EditorInput/common/BlockFormatDropDown/index.js +2 -0
  118. package/dist/es/f/fields/EditorInput/common/BlockFormatDropDown/styles.scss +55 -0
  119. package/dist/es/f/fields/EditorInput/common/ColorPicker/ColorPicker.js +83 -0
  120. package/dist/es/f/fields/EditorInput/common/ColorPicker/index.js +2 -0
  121. package/dist/es/f/fields/EditorInput/common/ColorPicker/styles.scss +36 -0
  122. package/dist/es/f/fields/EditorInput/common/FontSizeDropDown/FontSizeDropDown.js +81 -0
  123. package/dist/es/f/fields/EditorInput/common/FontSizeDropDown/index.js +2 -0
  124. package/dist/es/f/fields/EditorInput/common/FontSizeDropDown/styles.scss +55 -0
  125. package/dist/es/f/fields/EditorInput/common/ToolbarPlugin/ToolbarPlugin.js +283 -0
  126. package/dist/es/f/fields/EditorInput/common/ToolbarPlugin/index.js +2 -0
  127. package/dist/es/f/fields/EditorInput/common/ToolbarPlugin/styles.scss +56 -0
  128. package/dist/es/f/fields/EditorInput/common/index.js +5 -2
  129. package/dist/es/f/fields/EditorInput/styles.scss +109 -25
  130. package/dist/es/f/fields/TextInput/styles.scss +5 -2
  131. package/dist/es/utils/hooks/index.js +2 -1
  132. package/dist/es/utils/hooks/useOutsideClick.js +19 -0
  133. package/dist/es/utils/index.js +1 -1
  134. package/package.json +13 -5
  135. package/src/stories/a/Quote.stories.jsx +30 -10
  136. package/src/stories/a/Tooltip.stories.jsx +80 -0
  137. package/src/stories/a/XMLEditor.stories.jsx +6 -1
  138. package/src/ui/a/People/styles.scss +1 -1
  139. package/src/ui/a/Quote/Quote.jsx +16 -9
  140. package/src/ui/a/Quote/styles.scss +16 -37
  141. package/src/ui/a/Tooltip/Tooltip.jsx +83 -0
  142. package/src/ui/a/Tooltip/index.js +2 -0
  143. package/src/ui/a/Tooltip/styles.scss +53 -0
  144. package/src/ui/a/index.js +1 -0
  145. package/src/ui/b/ExpandableLexicalPreview/ExpandableLexicalPreview.jsx +1 -1
  146. package/src/ui/b/ExpandableLexicalPreview/common/ExpandButton/ExpandButton.jsx +1 -1
  147. package/src/ui/f/common/Description/styles.scss +1 -2
  148. package/src/ui/f/fields/EditorInput/EditorInput.jsx +21 -4
  149. package/src/ui/f/fields/EditorInput/common/BlockFormatDropDown/BlockFormatDropDown.jsx +292 -0
  150. package/src/ui/f/fields/EditorInput/common/BlockFormatDropDown/index.js +2 -0
  151. package/src/ui/f/fields/EditorInput/common/BlockFormatDropDown/styles.scss +55 -0
  152. package/src/ui/f/fields/EditorInput/common/ColorPicker/ColorPicker.jsx +110 -0
  153. package/src/ui/f/fields/EditorInput/common/ColorPicker/index.js +2 -0
  154. package/src/ui/f/fields/EditorInput/common/ColorPicker/styles.scss +36 -0
  155. package/src/ui/f/fields/EditorInput/common/FontSizeDropDown/FontSizeDropDown.jsx +134 -0
  156. package/src/ui/f/fields/EditorInput/common/FontSizeDropDown/index.js +2 -0
  157. package/src/ui/f/fields/EditorInput/common/FontSizeDropDown/styles.scss +55 -0
  158. package/src/ui/f/fields/EditorInput/common/ToolbarPlugin/ToolbarPlugin.jsx +431 -0
  159. package/src/ui/f/fields/EditorInput/common/ToolbarPlugin/index.js +2 -0
  160. package/src/ui/f/fields/EditorInput/common/ToolbarPlugin/styles.scss +56 -0
  161. package/src/ui/f/fields/EditorInput/common/index.js +6 -0
  162. package/src/ui/f/fields/EditorInput/styles.scss +109 -25
  163. package/src/ui/f/fields/TextInput/styles.scss +5 -2
  164. package/src/ui/utils/hooks/index.js +1 -0
  165. package/src/ui/utils/hooks/useOutsideClick.js +23 -0
  166. package/src/ui/utils/index.js +1 -1
  167. package/tests/__snapshots__/Storyshots.test.js.snap +777 -409
  168. package/tests/mockResizeObserver.js +9 -0
  169. package/tests/test-setup.js +3 -0
  170. package/dist/cjs/f/fields/EditorInput/common/Toolbar.js +0 -257
  171. package/dist/es/f/fields/EditorInput/common/Toolbar.js +0 -246
  172. package/src/ui/f/fields/EditorInput/common/Toolbar.jsx +0 -356
  173. package/src/ui/f/fields/EditorInput/common/index.jsx +0 -3
@@ -0,0 +1,80 @@
1
+ /* @pareto-engineering/generator-front 1.0.12 */
2
+ import * as React from 'react'
3
+ import { Tooltip, Button } from 'ui'
4
+
5
+ export default {
6
+ title :'a/Tooltip',
7
+ component :Tooltip,
8
+ subcomponents:{
9
+ // Item:Tooltip.Item
10
+ },
11
+ decorators:[
12
+ // storyfn => <div className="">{ storyfn() }</div>,
13
+ ],
14
+ argTypes:{
15
+ backgroundColor:{ control: 'color' },
16
+ },
17
+ }
18
+
19
+ const ariaDescribedby = 'test-tooltip'
20
+
21
+ export const Base = {
22
+ args:{
23
+ children:(
24
+ <div>
25
+ <ul>
26
+ <li>This is the tooltips content</li>
27
+ <li>Style it the way you want!</li>
28
+ <li>It&apos;s a tooltip, no interactive elements please</li>
29
+ </ul>
30
+ </div>
31
+ ),
32
+ id:ariaDescribedby,
33
+ },
34
+ render:(args) => (
35
+ <div
36
+ style={{
37
+ paddingTop :'10rem',
38
+ width :'50%',
39
+ margin :'auto',
40
+ display :'flex',
41
+ flexDirection:'column',
42
+ alignItems :'center',
43
+ }}
44
+ >
45
+ <div aria-describedby={ariaDescribedby}>
46
+ <Button>
47
+ Hover on me!
48
+ </Button>
49
+ <Tooltip {...args} />
50
+ </div>
51
+ <p>
52
+ With some more content around
53
+ </p>
54
+ </div>
55
+ ),
56
+ }
57
+
58
+ export const Left = {
59
+ ...Base,
60
+ args:{
61
+ ...Base.args,
62
+ position:'left',
63
+ },
64
+ }
65
+
66
+ export const Right = {
67
+ ...Base,
68
+ args:{
69
+ ...Base.args,
70
+ position:'right',
71
+ },
72
+ }
73
+
74
+ export const Top = {
75
+ ...Base,
76
+ args:{
77
+ ...Base.args,
78
+ position:'top',
79
+ },
80
+ }
@@ -14,7 +14,12 @@ export default {
14
14
  }
15
15
 
16
16
  const Template = (args) => (
17
- <XMLEditor {...args} />
17
+ <div>
18
+ {/* Args as JSON */}
19
+ <pre>{ JSON.stringify(args, null, 2) }</pre>
20
+ </div>
21
+ // TOFIX: Commented out due to issues.
22
+ // <XMLEditor {...args} />
18
23
  )
19
24
 
20
25
  export const Base = Template.bind({})
@@ -13,7 +13,7 @@ $default-horizontal-margin: .5em;
13
13
  $default-grid-gap: 1em;
14
14
  $default-margin: 1.5rem;
15
15
  $default-image-margin: var(--default-image-margin, #{$default-margin});
16
- $default-color: var(--default-color, var(--grey));
16
+ $default-color: var(--default-color, var(--paragraph));
17
17
 
18
18
  .#{bem.$base}.people {
19
19
  display: grid;
@@ -39,13 +39,16 @@ const Quote = ({
39
39
  style={style}
40
40
  // {...otherProps}
41
41
  >
42
- <blockquote cite={source} className="blockquote uc">
43
- <p className="quotation c-x md-s0 s-1">
44
- {children}
42
+ <blockquote cite={source} className="blockquote">
43
+ <p className="quotation h2">
44
+ <span className="c-x">&ldquo;</span>
45
+ <span className="c-x">{children}</span>
46
+ <span className="c-x">&rdquo;</span>
45
47
  </p>
46
48
  </blockquote>
47
49
  <figcaption className="figcaption">
48
- <cite>{author}</cite>
50
+ <span className="x-metadata c-x">-</span>
51
+ <cite className="x-metadata c-x">{author}</cite>
49
52
  </figcaption>
50
53
  </figure>
51
54
  )
@@ -64,27 +67,31 @@ Quote.propTypes = {
64
67
  /**
65
68
  * The React-written, css properties for this element.
66
69
  */
67
- style :PropTypes.objectOf(PropTypes.string),
70
+ style:PropTypes.objectOf(PropTypes.string),
71
+
68
72
  /**
69
73
  * The children jsx
70
74
  */
71
75
  children:PropTypes.node.isRequired,
76
+
72
77
  /**
73
78
  * A URL for the source of the quotation
74
79
  */
75
- source :PropTypes.string,
80
+ source:PropTypes.string,
81
+
76
82
  /**
77
83
  * text representation of the source
78
84
  */
79
- author :PropTypes.string,
85
+ author:PropTypes.string,
86
+
80
87
  /**
81
88
  * The color of the quotation text
82
89
  */
83
- color :PropTypes.string,
90
+ color:PropTypes.string,
84
91
  }
85
92
 
86
93
  Quote.defaultProps = {
87
- color:'main1',
94
+ color:'highlighted',
88
95
  }
89
96
 
90
97
  export default Quote
@@ -4,53 +4,32 @@
4
4
  @use "@pareto-engineering/styles/src/mixins";
5
5
  @use "@pareto-engineering/styles/src/globals" as *;
6
6
 
7
+ $default-gap: 1.5rem;
7
8
 
8
9
  .#{bem.$base}.quote {
9
- align-items: center;
10
+ border-left: 3px solid var(--x);
10
11
  display: flex;
11
12
  flex-direction: column;
12
13
 
13
- .blockquote {
14
+ > .blockquote {
14
15
  margin: 0;
15
- padding: 0;
16
- }
17
-
18
- .figcaption {
19
- padding: 0;
20
- }
21
16
 
22
- @include mixins.media($from:$sm-md) {
23
- .blockquote {
24
- .quotation {
25
- display: inline;
26
- }
27
-
28
- &::before {
29
- color: transparent;
30
- content: "\201C";
31
- font-size: 4em;
32
- line-height: 0;
33
- opacity: inherit;
34
- position: static;
35
- -webkit-text-stroke: 1px var(--x);
36
- vertical-align: -.4em;
37
- }
38
-
39
- &::after {
40
- color: transparent;
41
- content: "\201D";
42
- font-size: 4em;
43
- line-height: 0;
44
- margin-left: -.1em;
45
- -webkit-text-stroke: 1px var(--x);
46
- vertical-align: -.6em;
47
- }
17
+ > .h2 {
18
+ margin-left: 0;
19
+ margin-top: 0;
48
20
  }
49
21
 
50
- .figcaption {
51
- margin: 0;
22
+ > .quotation {
23
+ margin-left: $default-gap;
52
24
  }
53
25
  }
54
- }
55
26
 
27
+ > .figcaption {
28
+ margin-left: $default-gap;
29
+ padding: 0;
56
30
 
31
+ > cite {
32
+ font-style: normal;
33
+ }
34
+ }
35
+ }
@@ -0,0 +1,83 @@
1
+ /* @pareto-engineering/generator-front 1.0.12 */
2
+ import * as React from 'react'
3
+
4
+ import PropTypes from 'prop-types'
5
+
6
+ import styleNames from '@pareto-engineering/bem/exports'
7
+
8
+ import './styles.scss'
9
+
10
+ // Local Definitions
11
+
12
+ const baseClassName = styleNames.base
13
+
14
+ const componentClassName = 'tooltip'
15
+
16
+ /**
17
+ * This is the component description.
18
+ */
19
+ const Tooltip = ({
20
+ id,
21
+ className:userClassName,
22
+ style,
23
+ position,
24
+ color,
25
+ children,
26
+ // ...otherProps
27
+ }) => (
28
+ <div
29
+ id={id}
30
+ className={[
31
+ baseClassName,
32
+ componentClassName,
33
+ userClassName,
34
+ position,
35
+ `x-${color}`,
36
+ ]
37
+ .filter((e) => e)
38
+ .join(' ')}
39
+ style={style}
40
+ role="tooltip"
41
+ >
42
+ {children}
43
+ </div>
44
+ )
45
+
46
+ Tooltip.propTypes = {
47
+ /**
48
+ * The HTML id for this element
49
+ */
50
+ id:PropTypes.string.isRequired,
51
+
52
+ /**
53
+ * The HTML class names for this element
54
+ */
55
+ className:PropTypes.string,
56
+
57
+ /**
58
+ * The React-written, css properties for this element.
59
+ */
60
+ style:PropTypes.objectOf(PropTypes.string),
61
+
62
+ /**
63
+ * The children JSX
64
+ */
65
+ children:PropTypes.node.isRequired,
66
+
67
+ /**
68
+ * The position of the tooltip with respect to the trigger element
69
+ */
70
+ position:PropTypes.oneOf(['top', 'bottom', 'left', 'right']),
71
+
72
+ /**
73
+ * The base color of the tooltip
74
+ */
75
+ color:PropTypes.string,
76
+ }
77
+
78
+ Tooltip.defaultProps = {
79
+ position:'bottom',
80
+ color :'background-cards',
81
+ }
82
+
83
+ export default Tooltip
@@ -0,0 +1,2 @@
1
+ /* @pareto-engineering/generator-front 1.0.12 */
2
+ export { default as Tooltip } from './Tooltip'
@@ -0,0 +1,53 @@
1
+ /* @pareto-engineering/generator-front 1.0.12 */
2
+
3
+ @use "@pareto-engineering/bem";
4
+
5
+ $default-block-padding: calc(var(--theme-default-padding) / 2);
6
+ $default-inline-padding: var(--theme-default-padding);
7
+ $default-width: var(--tooltip-width, 20rem);
8
+
9
+ .#{bem.$base}.tooltip {
10
+ background: var(--x);
11
+ border: var(--theme-default-border-style) var(--ui-lines);
12
+ border-radius: calc(var(--theme-default-border-radius) / 2);
13
+ opacity: 0;
14
+ padding: $default-block-padding $default-inline-padding;
15
+ position: absolute;
16
+ transform: translateX(var(--horizontal, 0)) translateY(var(--vertical, 0));
17
+ transition: opacity .2s ease, transform .2s ease;
18
+ width: $default-width;
19
+ z-index: 10;
20
+
21
+ :has(> &) {
22
+ position: relative;
23
+
24
+ &:is(:hover, :focus-visible, :active) > .#{bem.$base}.tooltip {
25
+ opacity: 1;
26
+ transition-delay: 200ms;
27
+ }
28
+ }
29
+
30
+ &.top {
31
+ --horizontal: -50%;
32
+ bottom: calc(100% + $default-block-padding);
33
+ left: 50%;
34
+ }
35
+
36
+ &.right {
37
+ --vertical: 50%;
38
+ bottom: 50%;
39
+ left: calc(100% + $default-inline-padding);
40
+ }
41
+
42
+ &.bottom {
43
+ --horizontal: -50%;
44
+ left: 50%;
45
+ top: calc(100% + $default-block-padding);
46
+ }
47
+
48
+ &.left {
49
+ --vertical: 50%;
50
+ bottom: 50%;
51
+ right: calc(100% + $default-inline-padding);
52
+ }
53
+ }
package/src/ui/a/index.js CHANGED
@@ -28,3 +28,4 @@ export { ToggleSwitch } from './ToggleSwitch'
28
28
  export { XMLEditor } from './XMLEditor'
29
29
  export { LexicalPreview } from './LexicalPreview'
30
30
  export { DatePicker } from './DatePicker'
31
+ export { Tooltip } from './Tooltip'
@@ -10,7 +10,7 @@ import { ListItemNode, ListNode } from '@lexical/list'
10
10
 
11
11
  import PropTypes from 'prop-types'
12
12
  import styleNames from '@pareto-engineering/bem/exports'
13
- import { Button } from '@pareto-engineering/design-system'
13
+ import { Button } from '../Button'
14
14
  import './styles.scss'
15
15
  import { ExpandButton } from './common'
16
16
 
@@ -6,7 +6,7 @@ import { useLexicalComposerContext } from '@lexical/react/LexicalComposerContext
6
6
 
7
7
  import PropTypes from 'prop-types'
8
8
  import styleNames from '@pareto-engineering/bem/exports'
9
- import { Button } from '@pareto-engineering/design-system'
9
+ import { Button } from '../../../Button'
10
10
 
11
11
  // Local Definitions
12
12
 
@@ -5,6 +5,5 @@
5
5
 
6
6
  .#{bem.$base}.description {
7
7
  color: var(--x);
8
+ height: 0;
8
9
  }
9
-
10
-
@@ -9,10 +9,15 @@ import { ContentEditable } from '@lexical/react/LexicalContentEditable'
9
9
  import { OnChangePlugin } from '@lexical/react/LexicalOnChangePlugin'
10
10
  import { HistoryPlugin } from '@lexical/react/LexicalHistoryPlugin'
11
11
  import { LinkPlugin } from '@lexical/react/LexicalLinkPlugin'
12
+ import LexicalClickableLinkPlugin from '@lexical/react/LexicalClickableLinkPlugin'
12
13
  import { ListPlugin } from '@lexical/react/LexicalListPlugin'
14
+ import LexicalErrorBoundary from '@lexical/react/LexicalErrorBoundary'
13
15
  import { TabIndentationPlugin } from '@lexical/react/LexicalTabIndentationPlugin'
14
16
  import { AutoLinkNode, LinkNode } from '@lexical/link'
15
17
  import { ListItemNode, ListNode } from '@lexical/list'
18
+ import { CheckListPlugin } from '@lexical/react/LexicalCheckListPlugin'
19
+ import { HeadingNode, QuoteNode } from '@lexical/rich-text'
20
+ import { CodeHighlightNode, CodeNode } from '@lexical/code'
16
21
 
17
22
  import PropTypes from 'prop-types'
18
23
  import styleNames from '@pareto-engineering/bem/exports'
@@ -20,7 +25,7 @@ import styleNames from '@pareto-engineering/bem/exports'
20
25
  // Local Definitions
21
26
 
22
27
  import { FormLabel, FormDescription } from '../../common'
23
- import { Toolbar, TreeViewPlugin, StopPropagationPlugin } from './common'
28
+ import { ToolbarPlugin, TreeViewPlugin, StopPropagationPlugin } from './common'
24
29
 
25
30
  import './styles.scss'
26
31
 
@@ -107,8 +112,17 @@ const EditorInput = ({
107
112
  strikethrough:'strikethrough',
108
113
  underline :'underlined',
109
114
  },
115
+ list:{
116
+ listitemChecked :'lexical-list-item-checked',
117
+ listitemUnchecked:'lexical-list-item-unchecked',
118
+ },
119
+ code:'lexical-code',
110
120
  },
111
121
  nodes:[
122
+ HeadingNode,
123
+ QuoteNode,
124
+ CodeNode,
125
+ CodeHighlightNode,
112
126
  AutoLinkNode,
113
127
  LinkNode,
114
128
  ListNode,
@@ -145,18 +159,21 @@ const EditorInput = ({
145
159
  {label}
146
160
  </FormLabel>
147
161
 
148
- { !disabled && <Toolbar /> }
162
+ { !disabled && <ToolbarPlugin /> }
149
163
  <RichTextPlugin
150
164
  contentEditable={(
151
165
  <ContentEditable
152
- id={name}
153
166
  className="content-editable"
167
+ id={name}
154
168
  />
155
169
  )}
170
+ ErrorBoundary={LexicalErrorBoundary}
156
171
  />
172
+ <ListPlugin />
173
+ <CheckListPlugin />
157
174
  <OnChangePlugin onChange={onChange} />
158
175
  <LinkPlugin />
159
- <ListPlugin />
176
+ <LexicalClickableLinkPlugin />
160
177
  <TabIndentationPlugin />
161
178
  <HistoryPlugin />
162
179
  { stopPropagationKeys && (