@papillonarts/components 0.39.0 → 0.41.0

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 (34) hide show
  1. package/build/Legacy/Alert/Alert.type.d.ts.map +1 -1
  2. package/build/Legacy/Alert/Alert.type.js +3 -1
  3. package/build/Legacy/Alert/__tests__/Alert.doc.md +74 -41
  4. package/build/Legacy/Blankslate/__tests__/Blankslate.doc.md +60 -22
  5. package/build/Legacy/Breadcrumb/__tests__/Breadcrumb.doc.md +39 -13
  6. package/build/Legacy/Button/__tests__/Button.doc.md +339 -0
  7. package/build/Legacy/Dropdown/__tests__/Dropdown.doc.md +54 -0
  8. package/build/Legacy/ErrorBoundary/ErrorBoundary.type.d.ts.map +1 -1
  9. package/build/Legacy/ErrorBoundary/__tests__/ErrorBoundary.doc.md +33 -0
  10. package/build/Legacy/Form/Checkbox/__tests__/Checkbox.doc.md +87 -0
  11. package/build/Legacy/Form/Input/__tests__/Input.doc.md +84 -0
  12. package/build/Legacy/Form/Radio/__tests__/Radio.doc.md +66 -0
  13. package/build/Legacy/Grid/DisplayTable/__tests__/DisplayTable.doc.md +34 -0
  14. package/build/Legacy/Grid/FlexGrid/FlexGrid.js +2 -2
  15. package/build/Legacy/Grid/FlexGrid/__tests__/FlexGrid.doc.md +158 -0
  16. package/build/Legacy/Icon/__tests__/Icon.doc.md +58 -0
  17. package/build/Legacy/Label/__tests__/Label.doc.md +33 -0
  18. package/build/Legacy/Loader/__tests__/Loader.doc.md +61 -0
  19. package/build/Legacy/Markdown/__tests__/Markdown.doc.md +28 -13
  20. package/build/Legacy/Navigation/Menu/__tests__/Menu.doc.md +53 -0
  21. package/build/Legacy/Navigation/TabNav/__tests__/TabNav.doc.md +99 -0
  22. package/build/Legacy/Navigation/UnderlineNav/__tests__/UnderlineNav.doc.md +106 -0
  23. package/build/Legacy/Pagination/PreviousNext/__tests__/PreviousNext.doc.md +57 -0
  24. package/build/Legacy/Popover/__tests__/Popover.doc.md +260 -0
  25. package/build/Legacy/Progress/__tests__/Progress.doc.md +51 -0
  26. package/build/Legacy/Select/__tests__/Select.doc.md +54 -0
  27. package/build/Legacy/SelectMenu/__tests__/SelectMenu.doc.md +35 -0
  28. package/build/Legacy/Subhead/__tests__/Subhead.doc.md +43 -0
  29. package/build/Legacy/SyntaxHighlighter/__tests__/SyntaxHighlighter.doc.md +45 -21
  30. package/build/Legacy/Toast/__tests__/Toast.doc.md +73 -0
  31. package/build/Modern/Flash/__tests__/Flash.doc.md +151 -6
  32. package/build/Modern/Link/__tests__/Link.doc.md +91 -5
  33. package/build/Modern/Pagination/__tests__/Pagination.doc.md +89 -7
  34. package/package.json +4 -4
@@ -0,0 +1,260 @@
1
+ # Features
2
+
3
+ > Popovers are used to bring attention to specific user interface elements, typically to suggest an action or to guide users through a new experience.
4
+
5
+ ```
6
+ Popover all props and variants
7
+ ```
8
+
9
+ ## Props
10
+
11
+ ```typescript
12
+ export interface IPopover {
13
+ className?: string
14
+ variant?: string
15
+ size?: string
16
+ intro: string
17
+ heading: string
18
+ message: string
19
+ acknowledge: string
20
+ introOnClick: (value) => void
21
+ acknowledgeOnClick: (value) => void
22
+ }
23
+ ```
24
+
25
+ ## Variants
26
+
27
+ ```
28
+ Default
29
+
30
+ DefaultLarge
31
+
32
+ Bottom
33
+
34
+ BottomRight
35
+
36
+ BottomLeft
37
+
38
+ Left
39
+
40
+ LeftBottom
41
+
42
+ LeftTop
43
+
44
+ Right
45
+
46
+ RightBottom
47
+
48
+ RightTop
49
+
50
+ TopLeft
51
+
52
+ TopRight
53
+ ```
54
+
55
+ ### Default
56
+
57
+ > Popover default variant
58
+
59
+ ```tsx
60
+ <Popover
61
+ intro={intro}
62
+ heading={heading}
63
+ message={message}
64
+ acknowledge={acknowledge}
65
+ introOnClick={action('introOnClick')}
66
+ acknowledgeOnClick={action('acknowledgeOnClick')}
67
+ />
68
+ ```
69
+
70
+ ### Default Large
71
+
72
+ > Popover default large variant
73
+
74
+ ```tsx
75
+ <Popover
76
+ intro={intro}
77
+ heading={heading}
78
+ message={message}
79
+ acknowledge={acknowledge}
80
+ size={PopoverSize.Large}
81
+ introOnClick={action('introOnClick')}
82
+ acknowledgeOnClick={action('acknowledgeOnClick')}
83
+ />
84
+ ```
85
+
86
+ ### Bottom
87
+
88
+ > Popover bottom variant
89
+
90
+ ```tsx
91
+ <Popover
92
+ intro={intro}
93
+ heading={heading}
94
+ message={message}
95
+ acknowledge={acknowledge}
96
+ variant={PopoverVariant.Bottom}
97
+ introOnClick={action('introOnClick')}
98
+ acknowledgeOnClick={action('acknowledgeOnClick')}
99
+ />
100
+ ```
101
+
102
+ ### Bottom Right
103
+
104
+ > Popover bottom right variant
105
+
106
+ ```tsx
107
+ <Popover
108
+ intro={intro}
109
+ heading={heading}
110
+ message={message}
111
+ acknowledge={acknowledge}
112
+ variant={PopoverVariant.BottomRight}
113
+ introOnClick={action('introOnClick')}
114
+ acknowledgeOnClick={action('acknowledgeOnClick')}
115
+ />
116
+ ```
117
+
118
+ ### Bottom Left
119
+
120
+ > Popover bottom left variant
121
+
122
+ ```tsx
123
+ <Popover
124
+ intro={intro}
125
+ heading={heading}
126
+ message={message}
127
+ acknowledge={acknowledge}
128
+ variant={PopoverVariant.BottomLeft}
129
+ introOnClick={action('introOnClick')}
130
+ acknowledgeOnClick={action('acknowledgeOnClick')}
131
+ />
132
+ ```
133
+
134
+ ### Left
135
+
136
+ > Popover left variant
137
+
138
+ ```tsx
139
+ <Popover
140
+ intro={intro}
141
+ heading={heading}
142
+ message={message}
143
+ acknowledge={acknowledge}
144
+ variant={PopoverVariant.Left}
145
+ introOnClick={action('introOnClick')}
146
+ acknowledgeOnClick={action('acknowledgeOnClick')}
147
+ />
148
+ ```
149
+
150
+ ### Left Bottom
151
+
152
+ > Popover left bottom variant
153
+
154
+ ```tsx
155
+ <Popover
156
+ intro={intro}
157
+ heading={heading}
158
+ message={message}
159
+ acknowledge={acknowledge}
160
+ variant={PopoverVariant.LeftBottom}
161
+ introOnClick={action('introOnClick')}
162
+ acknowledgeOnClick={action('acknowledgeOnClick')}
163
+ />
164
+ ```
165
+
166
+ ### Left Top
167
+
168
+ > Popover left top variant
169
+
170
+ ```tsx
171
+ <Popover
172
+ intro={intro}
173
+ heading={heading}
174
+ message={message}
175
+ acknowledge={acknowledge}
176
+ variant={PopoverVariant.LeftTop}
177
+ introOnClick={action('introOnClick')}
178
+ acknowledgeOnClick={action('acknowledgeOnClick')}
179
+ />
180
+ ```
181
+
182
+ ### Right
183
+
184
+ > Popover right variant
185
+
186
+ ```tsx
187
+ <Popover
188
+ intro={intro}
189
+ heading={heading}
190
+ message={message}
191
+ acknowledge={acknowledge}
192
+ variant={PopoverVariant.Right}
193
+ introOnClick={action('introOnClick')}
194
+ acknowledgeOnClick={action('acknowledgeOnClick')}
195
+ />
196
+ ```
197
+
198
+ ### Right Bottom
199
+
200
+ > Popover right bottom variant
201
+
202
+ ```tsx
203
+ <Popover
204
+ intro={intro}
205
+ heading={heading}
206
+ message={message}
207
+ acknowledge={acknowledge}
208
+ variant={PopoverVariant.RightBottom}
209
+ introOnClick={action('introOnClick')}
210
+ acknowledgeOnClick={action('acknowledgeOnClick')}
211
+ />
212
+ ```
213
+
214
+ ### Right Top
215
+
216
+ > Popover right top variant
217
+
218
+ ```tsx
219
+ <Popover
220
+ intro={intro}
221
+ heading={heading}
222
+ message={message}
223
+ acknowledge={acknowledge}
224
+ variant={PopoverVariant.RightTop}
225
+ introOnClick={action('introOnClick')}
226
+ acknowledgeOnClick={action('acknowledgeOnClick')}
227
+ />
228
+ ```
229
+
230
+ ### Top Left
231
+
232
+ > Popover top left variant
233
+
234
+ ```tsx
235
+ <Popover
236
+ intro={intro}
237
+ heading={heading}
238
+ message={message}
239
+ acknowledge={acknowledge}
240
+ variant={PopoverVariant.TopLeft}
241
+ introOnClick={action('introOnClick')}
242
+ acknowledgeOnClick={action('acknowledgeOnClick')}
243
+ />
244
+ ```
245
+
246
+ ### Top Right
247
+
248
+ > Popover top right variant
249
+
250
+ ```tsx
251
+ <Popover
252
+ intro={intro}
253
+ heading={heading}
254
+ message={message}
255
+ acknowledge={acknowledge}
256
+ variant={PopoverVariant.TopRight}
257
+ introOnClick={action('introOnClick')}
258
+ acknowledgeOnClick={action('acknowledgeOnClick')}
259
+ />
260
+ ```
@@ -0,0 +1,51 @@
1
+ # Features
2
+
3
+ > Use progress components to visualize task completion. The Progress class adds a background color and aligns its children horizontally with flexbox. The children (Progress-item) should be individually colored with background utilities and sized with inline width styles in percentages. Overflow is hidden, so children that overflow will be clipped.
4
+
5
+ ```
6
+ Progress all props and variants
7
+ ```
8
+
9
+ ## Props
10
+
11
+ ```typescript
12
+ export interface IProgress {
13
+ className?: string
14
+ variant?: string
15
+ percentage: number
16
+ }
17
+ ```
18
+
19
+ ## Variants
20
+
21
+ ```
22
+ Normal
23
+
24
+ Large
25
+
26
+ Small
27
+ ```
28
+
29
+ ### Normal
30
+
31
+ > Progress normal variant
32
+
33
+ ```tsx
34
+ <Progress variant={ProgressVariant.Normal} percentage={50} />
35
+ ```
36
+
37
+ ### Large
38
+
39
+ > Progress large variant
40
+
41
+ ```tsx
42
+ <Progress variant={ProgressVariant.Large} percentage={50} />
43
+ ```
44
+
45
+ ### Small
46
+
47
+ > Progress small variant
48
+
49
+ ```tsx
50
+ <Progress variant={ProgressVariant.Small} percentage={50} />
51
+ ```
@@ -0,0 +1,54 @@
1
+ # Features
2
+
3
+ > Selects are lightweight context menus for housing navigation and actions. They're great for instances where you don't need the full power (and code) of the select menu.
4
+
5
+ ```
6
+ Select all props and variants
7
+ ```
8
+
9
+ ## Props
10
+
11
+ ```typescript
12
+ export interface ISelect {
13
+ id?: string
14
+ className?: string
15
+ selectedText: string
16
+ items: IItem[]
17
+ onChange: (value) => void
18
+ state?: string
19
+ }
20
+ ```
21
+
22
+ ## Variants
23
+
24
+ ```
25
+ Default
26
+
27
+ Active
28
+
29
+ Inactive
30
+ ```
31
+
32
+ ### Default
33
+
34
+ > Select default variant
35
+
36
+ ```tsx
37
+ <Select selectedText={selectedText} items={items} onChange={action('onChange')} />
38
+ ```
39
+
40
+ ### Active
41
+
42
+ > Select active variant
43
+
44
+ ```tsx
45
+ <Select selectedText={selectedText} items={items} onChange={action('onChange')} state={SelectState.Active} />
46
+ ```
47
+
48
+ ### Inactive
49
+
50
+ > Select inactive variant
51
+
52
+ ```tsx
53
+ <Select selectedText={selectedText} items={items} onChange={action('onChange')} state={SelectState.Inactive} />
54
+ ```
@@ -0,0 +1,35 @@
1
+ # Features
2
+
3
+ > The SelectMenu component provides advanced support for navigation, filtering, and more. Any menu can make use of JavaScript-enabled live filtering, selected states, tabbed lists, and keyboard navigation with a bit of markup.
4
+
5
+ ```
6
+ SelectMenu all props and variants
7
+ ```
8
+
9
+ ## Props
10
+
11
+ ```typescript
12
+ export interface ISelectMenu {
13
+ className?: string
14
+ summary: string
15
+ icon: string
16
+ title?: string
17
+ ariaAttr: IAriaAttr
18
+ items: IItem[]
19
+ onClick: (value) => void
20
+ }
21
+ ```
22
+
23
+ ## Variants
24
+
25
+ ```
26
+ Default
27
+ ```
28
+
29
+ ### Default
30
+
31
+ > SelectMenu default variant
32
+
33
+ ```tsx
34
+ <SelectMenu summary={summary} icon={IconName.ChevronDown16} title={title} ariaAttr={ariaAttr} items={items} onClick={action('onClick')} />
35
+ ```
@@ -0,0 +1,43 @@
1
+ # Features
2
+
3
+ > The basic Subhead consists of a .Subhead container, which has a light gray bottom border. Use .Subhead-heading for the heading itself. It's an <h2> sized heading with normal font-weight.
4
+
5
+ > Use a heading element whenever possible as they can be used as navigation for assistive technologies, and avoid skipping levels.
6
+
7
+ ```
8
+ Subhead all props and variants
9
+ ```
10
+
11
+ ## Props
12
+
13
+ ```typescript
14
+ export interface ISubhead {
15
+ className?: string
16
+ heading: string
17
+ isSpacious?: boolean
18
+ }
19
+ ```
20
+
21
+ ## Variants
22
+
23
+ ```
24
+ Plain
25
+
26
+ Spacious
27
+ ```
28
+
29
+ ### Plain
30
+
31
+ > Subhead plain variant
32
+
33
+ ```tsx
34
+ <Subhead heading="Plain subhead" />
35
+ ```
36
+
37
+ ### Spacious
38
+
39
+ > Subhead spacious variant
40
+
41
+ ```tsx
42
+ <Subhead heading="Spacious subhead" isSpacious={true} />
43
+ ```
@@ -1,26 +1,50 @@
1
- # SyntaxHighlighter
1
+ # Features
2
+
3
+ ```
4
+ SyntaxHighlighter all props and variants
5
+ ```
6
+
7
+ ## Props
2
8
 
3
- > SyntaxHighlighter component all features
9
+ ```typescript
10
+ export interface ISyntaxHighlighter extends ISyntaxHighlighterBase {
11
+ highlighter?: string
12
+ }
4
13
 
14
+ export interface ISyntaxHighlighterBase {
15
+ language?: string
16
+ style?: string
17
+ children?: string
18
+ }
5
19
  ```
6
- # Features
7
20
 
8
- > Default
21
+ ## Variants
22
+
23
+ ```
24
+ Default
25
+
26
+ HLJSTypeScript
27
+
28
+ HLJSMarkdown
29
+
30
+ PrismTypeScript
31
+
32
+ PrismMarkdown
9
33
  ```
10
34
 
11
- ## Default
35
+ ### Default
12
36
 
13
- > Markdown component default feature
37
+ > SyntaxHighlighter default variant
14
38
 
15
- ```jsx
39
+ ```tsx
16
40
  <SyntaxHighlighter>{TypeScriptCode}</SyntaxHighlighter>
17
41
  ```
18
42
 
19
- ## HLJS TypeScript
43
+ ### HLJS TypeScript
20
44
 
21
- > Markdown component hljs typescript feature
45
+ > SyntaxHighlighter hljs typeScript variant
22
46
 
23
- ```jsx
47
+ ```tsx
24
48
  <SyntaxHighlighter
25
49
  highlighter={SyntaxHighlighterHighlighter.HLJS}
26
50
  language={SyntaxHighlighterLanguage.TypeScript}
@@ -30,19 +54,19 @@
30
54
  </SyntaxHighlighter>
31
55
  ```
32
56
 
33
- ## HLJS Markdown
57
+ ### HLJS Markdown
34
58
 
35
- > Markdown component hljs markdown feature
59
+ > SyntaxHighlighter hljs markdown variant
36
60
 
37
- ```jsx
38
- <Markdown highlighter={MarkdownHighlighter.HLJS}>{SyntaxHighlighterMarkdown}</Markdown>
61
+ ```tsx
62
+ <Markdown highlighter={MarkdownHighlighter.HLJS}>{SyntaxHighlighterDoc}</Markdown>
39
63
  ```
40
64
 
41
- ## Prism TypeScript
65
+ ### Prism TypeScript
42
66
 
43
- > Markdown component prism typescript feature
67
+ > SyntaxHighlighter prism typeScript variant
44
68
 
45
- ```jsx
69
+ ```tsx
46
70
  <SyntaxHighlighter
47
71
  highlighter={SyntaxHighlighterHighlighter.PRISM}
48
72
  language={SyntaxHighlighterLanguage.TypeScript}
@@ -52,10 +76,10 @@
52
76
  </SyntaxHighlighter>
53
77
  ```
54
78
 
55
- ## Prism Markdown
79
+ ### Prism Markdown
56
80
 
57
- > Markdown component prism markdown feature
81
+ > SyntaxHighlighter prism markdown variant
58
82
 
59
- ```jsx
60
- <Markdown highlighter={MarkdownHighlighter.PRISM}>{SyntaxHighlighterMarkdown}</Markdown>
83
+ ```tsx
84
+ <Markdown highlighter={MarkdownHighlighter.PRISM}>{SyntaxHighlighterDoc}</Markdown>
61
85
  ```
@@ -0,0 +1,73 @@
1
+ # Features
2
+
3
+ > Toasts are used to show live, time-sensitive feedback to users.
4
+
5
+ ```
6
+ Toast all props and variants
7
+ ```
8
+
9
+ ## Props
10
+
11
+ ```typescript
12
+ export interface IToast {
13
+ className?: string
14
+ variant?: string
15
+ text: string
16
+ isDismissable?: boolean
17
+ onClick?: (value) => void
18
+ }
19
+ ```
20
+
21
+ ## Variants
22
+
23
+ ```
24
+ Info
25
+
26
+ Success
27
+
28
+ Warning
29
+
30
+ Error
31
+
32
+ Dismissible
33
+ ```
34
+
35
+ ### Info
36
+
37
+ > Toast info variant
38
+
39
+ ```tsx
40
+ <Toast variant={ToastVariant.Info} text={text.info} />
41
+ ```
42
+
43
+ ### Success
44
+
45
+ > Toast success variant
46
+
47
+ ```tsx
48
+ <Toast variant={ToastVariant.Success} text={text.success} />
49
+ ```
50
+
51
+ ### Warning
52
+
53
+ > Toast warning variant
54
+
55
+ ```tsx
56
+ <Toast variant={ToastVariant.Warning} text={text.warning} />
57
+ ```
58
+
59
+ ### Error
60
+
61
+ > Toast error variant
62
+
63
+ ```tsx
64
+ <Toast variant={ToastVariant.Error} text={text.error} />
65
+ ```
66
+
67
+ ### Dismissible
68
+
69
+ > Toast dismissible variant
70
+
71
+ ```tsx
72
+ <Toast variant={ToastVariant.Info} text={text.dismissible} isdismissible={true} onClick={action('onClick')} />
73
+ ```