@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.
- package/build/Legacy/Alert/Alert.type.d.ts.map +1 -1
- package/build/Legacy/Alert/Alert.type.js +3 -1
- package/build/Legacy/Alert/__tests__/Alert.doc.md +74 -41
- package/build/Legacy/Blankslate/__tests__/Blankslate.doc.md +60 -22
- package/build/Legacy/Breadcrumb/__tests__/Breadcrumb.doc.md +39 -13
- package/build/Legacy/Button/__tests__/Button.doc.md +339 -0
- package/build/Legacy/Dropdown/__tests__/Dropdown.doc.md +54 -0
- package/build/Legacy/ErrorBoundary/ErrorBoundary.type.d.ts.map +1 -1
- package/build/Legacy/ErrorBoundary/__tests__/ErrorBoundary.doc.md +33 -0
- package/build/Legacy/Form/Checkbox/__tests__/Checkbox.doc.md +87 -0
- package/build/Legacy/Form/Input/__tests__/Input.doc.md +84 -0
- package/build/Legacy/Form/Radio/__tests__/Radio.doc.md +66 -0
- package/build/Legacy/Grid/DisplayTable/__tests__/DisplayTable.doc.md +34 -0
- package/build/Legacy/Grid/FlexGrid/FlexGrid.js +2 -2
- package/build/Legacy/Grid/FlexGrid/__tests__/FlexGrid.doc.md +158 -0
- package/build/Legacy/Icon/__tests__/Icon.doc.md +58 -0
- package/build/Legacy/Label/__tests__/Label.doc.md +33 -0
- package/build/Legacy/Loader/__tests__/Loader.doc.md +61 -0
- package/build/Legacy/Markdown/__tests__/Markdown.doc.md +28 -13
- package/build/Legacy/Navigation/Menu/__tests__/Menu.doc.md +53 -0
- package/build/Legacy/Navigation/TabNav/__tests__/TabNav.doc.md +99 -0
- package/build/Legacy/Navigation/UnderlineNav/__tests__/UnderlineNav.doc.md +106 -0
- package/build/Legacy/Pagination/PreviousNext/__tests__/PreviousNext.doc.md +57 -0
- package/build/Legacy/Popover/__tests__/Popover.doc.md +260 -0
- package/build/Legacy/Progress/__tests__/Progress.doc.md +51 -0
- package/build/Legacy/Select/__tests__/Select.doc.md +54 -0
- package/build/Legacy/SelectMenu/__tests__/SelectMenu.doc.md +35 -0
- package/build/Legacy/Subhead/__tests__/Subhead.doc.md +43 -0
- package/build/Legacy/SyntaxHighlighter/__tests__/SyntaxHighlighter.doc.md +45 -21
- package/build/Legacy/Toast/__tests__/Toast.doc.md +73 -0
- package/build/Modern/Flash/__tests__/Flash.doc.md +151 -6
- package/build/Modern/Link/__tests__/Link.doc.md +91 -5
- package/build/Modern/Pagination/__tests__/Pagination.doc.md +89 -7
- package/package.json +4 -4
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Alert.type.d.ts","sourceRoot":"","sources":["../../../src/Legacy/Alert/Alert.type.ts"],"names":[],"mappings":"AAAA,MAAM,WAAW,aAAa;IAC5B,OAAO,EAAE,MAAM,CAAA;IACf,IAAI,EAAE,MAAM,CAAA;IACZ,OAAO,EAAE,MAAM,CAAA;IACf,KAAK,EAAE,MAAM,CAAA;IACb,OAAO,EAAE,MAAM,CAAA;IACf,IAAI,EAAE,MAAM,CAAA;IACZ,MAAM,EAAE,MAAM,CAAA;CACf;AAED,eAAO,MAAM,YAAY,EAAE,aAQ1B,CAAA;AAED,MAAM,WAAW,aAAa;IAC5B,UAAU,EAAE,WAAW,CAAA;IACvB,SAAS,EAAE,MAAM,CAAA;IACjB,OAAO,EAAE,MAAM,CAAA;IACf,OAAO,EAAE,MAAM,CAAA;CAChB;AAED,eAAO,MAAM,YAAY,EAAE,aAU1B,CAAA;AAED,MAAM,WAAW,mBAAmB;IAClC,OAAO,CAAC,EAAE,CAAC,KAAK,CAAC,EAAE,MAAM,KAAK,IAAI,CAAA;IAClC,MAAM,CAAC,EAAE,CAAC,KAAK,CAAC,EAAE,MAAM,KAAK,IAAI,CAAA;CAClC;AAED,MAAM,WAAW,aAAa;IAC5B,MAAM,CAAC,EAAE,mBAAmB,CAAA;IAC5B,QAAQ,CAAC,EAAE,OAAO,CAAA;CACnB;AAED,MAAM,WAAW,WAAW;IAC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,SAAS,CAAC,EAAE,MAAM,CAAA;IAClB,OAAO,CAAC,EAAE,MAAM,CAAA;IAChB,QAAQ,EAAE,KAAK,CAAC,SAAS,CAAA;IACzB,OAAO,CAAC,EAAE,aAAa,CAAA;CACxB"}
|
|
@@ -1,111 +1,144 @@
|
|
|
1
|
-
#
|
|
1
|
+
# Features
|
|
2
2
|
|
|
3
|
-
>
|
|
3
|
+
> Flash messages, or alerts, inform users of successful or pending actions. Use them sparingly. Don't show more than one at a time.
|
|
4
4
|
|
|
5
5
|
```
|
|
6
|
-
|
|
6
|
+
Alert all props and variants
|
|
7
|
+
```
|
|
8
|
+
|
|
9
|
+
## Props
|
|
10
|
+
|
|
11
|
+
```typescript
|
|
12
|
+
export interface IAlert {
|
|
13
|
+
dataTestId?: IDataTestId
|
|
14
|
+
className?: string
|
|
15
|
+
variant?: string
|
|
16
|
+
children: React.ReactNode
|
|
17
|
+
consent?: IAlertConsent
|
|
18
|
+
}
|
|
19
|
+
```
|
|
20
|
+
|
|
21
|
+
## Variants
|
|
22
|
+
|
|
23
|
+
```
|
|
24
|
+
Default
|
|
25
|
+
|
|
26
|
+
DefaultMultipleParagraphs
|
|
27
|
+
|
|
28
|
+
Info
|
|
29
|
+
|
|
30
|
+
Warning
|
|
31
|
+
|
|
32
|
+
Error
|
|
33
|
+
|
|
34
|
+
Success
|
|
35
|
+
|
|
36
|
+
Full
|
|
37
|
+
|
|
38
|
+
Banner
|
|
39
|
+
|
|
40
|
+
DefaultConsentWithInput
|
|
7
41
|
|
|
8
|
-
|
|
9
|
-
> Info, Warning, Error, Success
|
|
10
|
-
> Full, Banner
|
|
11
|
-
> DefaultConsentWithInput, DefaultConsentWithoutInput
|
|
42
|
+
DefaultConsentWithoutInput
|
|
12
43
|
```
|
|
13
44
|
|
|
14
|
-
|
|
45
|
+
### Default
|
|
15
46
|
|
|
16
|
-
> Alert
|
|
47
|
+
> Alert default variant
|
|
48
|
+
> Flash messages start off looking decently neutral—they're just light blue rounded rectangles.
|
|
17
49
|
|
|
18
|
-
```
|
|
50
|
+
```tsx
|
|
19
51
|
<Alert variant={AlertVariant.Default}>{children}</Alert>
|
|
20
52
|
```
|
|
21
53
|
|
|
22
|
-
|
|
54
|
+
### Default Multiple Paragraphs
|
|
23
55
|
|
|
24
|
-
> Alert
|
|
56
|
+
> Alert default multiple paragraphs variant
|
|
57
|
+
> You can put multiple paragraphs of text in a flash message—the last paragraph's bottom margin will be automatically override.
|
|
25
58
|
|
|
26
|
-
```
|
|
59
|
+
```tsx
|
|
27
60
|
<Alert variant={AlertVariant.Default}>
|
|
28
61
|
<p>
|
|
29
|
-
This is a longer flash message in it's own paragraph. It ends up looking something like this. If we keep adding more text, it
|
|
62
|
+
This is a longer flash message in it's own paragraph. It ends up looking something like this. If we keep adding more text, it'll
|
|
30
63
|
eventually wrap to a new line.
|
|
31
64
|
</p>
|
|
32
65
|
<p>And this is another paragraph.</p>
|
|
33
66
|
</Alert>
|
|
34
67
|
```
|
|
35
68
|
|
|
36
|
-
|
|
69
|
+
### Info
|
|
37
70
|
|
|
38
|
-
> Alert
|
|
71
|
+
> Alert info variant
|
|
39
72
|
|
|
40
|
-
```
|
|
73
|
+
```tsx
|
|
41
74
|
<Alert variant={AlertVariant.Info}>{children}</Alert>
|
|
42
75
|
```
|
|
43
76
|
|
|
44
|
-
|
|
77
|
+
### Warning
|
|
45
78
|
|
|
46
|
-
> Alert
|
|
79
|
+
> Alert warning variant
|
|
47
80
|
|
|
48
|
-
```
|
|
81
|
+
```tsx
|
|
49
82
|
<Alert variant={AlertVariant.Warning}>{children}</Alert>
|
|
50
83
|
```
|
|
51
84
|
|
|
52
|
-
|
|
85
|
+
### Error
|
|
53
86
|
|
|
54
|
-
> Alert
|
|
87
|
+
> Alert error variant
|
|
55
88
|
|
|
56
|
-
```
|
|
89
|
+
```tsx
|
|
57
90
|
<Alert variant={AlertVariant.Error}>{children}</Alert>
|
|
58
91
|
```
|
|
59
92
|
|
|
60
|
-
|
|
93
|
+
### Success
|
|
61
94
|
|
|
62
|
-
> Alert
|
|
95
|
+
> Alert success variant
|
|
63
96
|
|
|
64
|
-
```
|
|
97
|
+
```tsx
|
|
65
98
|
<Alert variant={AlertVariant.Success}>{children}</Alert>
|
|
66
99
|
```
|
|
67
100
|
|
|
68
|
-
|
|
101
|
+
### Full
|
|
69
102
|
|
|
70
|
-
> Alert
|
|
103
|
+
> Alert full variant
|
|
71
104
|
|
|
72
|
-
```
|
|
105
|
+
```tsx
|
|
73
106
|
<Alert variant={AlertVariant.Full}>{children}</Alert>
|
|
74
107
|
```
|
|
75
108
|
|
|
76
|
-
|
|
109
|
+
### Banner
|
|
77
110
|
|
|
78
|
-
> Alert
|
|
111
|
+
> Alert banner variant
|
|
79
112
|
|
|
80
|
-
```
|
|
113
|
+
```tsx
|
|
81
114
|
<Alert variant={AlertVariant.Banner}>{children}</Alert>
|
|
82
115
|
```
|
|
83
116
|
|
|
84
|
-
|
|
117
|
+
### Default Consent With Input
|
|
85
118
|
|
|
86
|
-
> Alert
|
|
119
|
+
> Alert default consent with input variant
|
|
87
120
|
|
|
88
|
-
```
|
|
121
|
+
```tsx
|
|
89
122
|
<Alert variant={AlertVariant.Default} consent={getConsent({ hasInput: true })}>
|
|
90
123
|
{children}
|
|
91
124
|
</Alert>
|
|
92
125
|
```
|
|
93
126
|
|
|
94
|
-
|
|
127
|
+
### Default Consent Without Input
|
|
95
128
|
|
|
96
|
-
> Alert
|
|
129
|
+
> Alert default consent without input variant
|
|
97
130
|
|
|
98
|
-
```
|
|
131
|
+
```tsx
|
|
99
132
|
<Alert variant={AlertVariant.Default} consent={getConsent({ hasInput: false })}>
|
|
100
133
|
{children}
|
|
101
134
|
</Alert>
|
|
102
135
|
```
|
|
103
136
|
|
|
104
|
-
|
|
137
|
+
### DefaultConsentCustom
|
|
105
138
|
|
|
106
|
-
> Alert
|
|
139
|
+
> Alert default consent custom variant
|
|
107
140
|
|
|
108
|
-
```
|
|
141
|
+
```tsx
|
|
109
142
|
<Alert variant={AlertVariant.Default} consent={consent}>
|
|
110
143
|
{children}
|
|
111
144
|
</Alert>
|
|
@@ -1,57 +1,95 @@
|
|
|
1
|
-
#
|
|
1
|
+
# Features
|
|
2
2
|
|
|
3
|
-
>
|
|
3
|
+
> Blankslates are for when there is a lack of content within a page or section. Use them as placeholders to tell users why something isn't there. Be sure to provide an action to add content as well.
|
|
4
4
|
|
|
5
5
|
```
|
|
6
|
-
|
|
6
|
+
Blankslate all props and variants
|
|
7
|
+
```
|
|
8
|
+
|
|
9
|
+
## Props
|
|
10
|
+
|
|
11
|
+
```typescript
|
|
12
|
+
export interface IBlankslate {
|
|
13
|
+
className?: string
|
|
14
|
+
heading: string
|
|
15
|
+
text: string
|
|
16
|
+
variant?: string
|
|
17
|
+
hasCleanBackground?: boolean
|
|
18
|
+
}
|
|
19
|
+
```
|
|
20
|
+
|
|
21
|
+
## Variants
|
|
7
22
|
|
|
8
|
-
> Default, Narrow, Capped, Spacious, Large, CleanBackground
|
|
9
23
|
```
|
|
24
|
+
Default
|
|
10
25
|
|
|
11
|
-
|
|
26
|
+
Narrow
|
|
12
27
|
|
|
13
|
-
|
|
28
|
+
Capped
|
|
29
|
+
|
|
30
|
+
Spacious
|
|
31
|
+
|
|
32
|
+
Large
|
|
33
|
+
|
|
34
|
+
CleanBackground
|
|
35
|
+
```
|
|
14
36
|
|
|
15
|
-
|
|
37
|
+
### Default
|
|
38
|
+
|
|
39
|
+
> Blankslate default feature
|
|
40
|
+
|
|
41
|
+
> Wrap some content in the outer .blankslate wrapper to give it the blankslate appearance.
|
|
42
|
+
|
|
43
|
+
```tsx
|
|
16
44
|
<Blankslate variant={BlankslateVariant.Default} heading={heading} text={text} />
|
|
17
45
|
```
|
|
18
46
|
|
|
19
|
-
|
|
47
|
+
### Narrow
|
|
48
|
+
|
|
49
|
+
> Blankslate narrow feature
|
|
20
50
|
|
|
21
|
-
>
|
|
51
|
+
> Narrows the blankslate container to not occupy the entire available width.
|
|
22
52
|
|
|
23
|
-
```
|
|
53
|
+
```tsx
|
|
24
54
|
<Blankslate variant={BlankslateVariant.Narrow} heading={heading} text={text} />
|
|
25
55
|
```
|
|
26
56
|
|
|
27
|
-
|
|
57
|
+
### Capped
|
|
28
58
|
|
|
29
|
-
> Blankslate
|
|
59
|
+
> Blankslate capped feature
|
|
30
60
|
|
|
31
|
-
|
|
61
|
+
> Removes the border-radius on the top corners.
|
|
62
|
+
|
|
63
|
+
```tsx
|
|
32
64
|
<Blankslate variant={BlankslateVariant.Capped} heading={heading} text={text} />
|
|
33
65
|
```
|
|
34
66
|
|
|
35
|
-
|
|
67
|
+
### Spacious
|
|
68
|
+
|
|
69
|
+
> Blankslate spacious feature
|
|
36
70
|
|
|
37
|
-
>
|
|
71
|
+
> Significantly increases the vertical padding.
|
|
38
72
|
|
|
39
|
-
```
|
|
73
|
+
```tsx
|
|
40
74
|
<Blankslate variant={BlankslateVariant.Spacious} heading={heading} text={text} />
|
|
41
75
|
```
|
|
42
76
|
|
|
43
|
-
|
|
77
|
+
### Large
|
|
44
78
|
|
|
45
|
-
> Blankslate
|
|
79
|
+
> Blankslate large feature
|
|
46
80
|
|
|
47
|
-
|
|
81
|
+
> Increases the size of the text in the blankslate
|
|
82
|
+
|
|
83
|
+
```tsx
|
|
48
84
|
<Blankslate variant={BlankslateVariant.Large} heading={heading} text={text} />
|
|
49
85
|
```
|
|
50
86
|
|
|
51
|
-
|
|
87
|
+
### Clean Background
|
|
88
|
+
|
|
89
|
+
> Blankslate cleanBackground feature
|
|
52
90
|
|
|
53
|
-
>
|
|
91
|
+
> Removes the background-color and border.
|
|
54
92
|
|
|
55
|
-
```
|
|
93
|
+
```tsx
|
|
56
94
|
<Blankslate hasCleanBackground={true} heading={heading} text={text} />
|
|
57
95
|
```
|
|
@@ -1,33 +1,59 @@
|
|
|
1
|
-
#
|
|
1
|
+
# Features
|
|
2
2
|
|
|
3
|
-
>
|
|
3
|
+
> Breadcrumbs are used to show taxonomical context on pages that are many levels deep in a site’s hierarchy. Breadcrumbs show and link to parent, grandparent, and sometimes great-grandparent pages. Breadcrumbs are most appropriate on pages that:
|
|
4
|
+
|
|
5
|
+
> Are many levels deep on a site
|
|
6
|
+
|
|
7
|
+
> Do not have a section>level navigation
|
|
8
|
+
|
|
9
|
+
> May need the ability to quickly go back to the previous (parent) page
|
|
4
10
|
|
|
5
11
|
```
|
|
6
|
-
|
|
12
|
+
Breadcrumb all props and variants
|
|
13
|
+
```
|
|
14
|
+
|
|
15
|
+
## Props
|
|
16
|
+
|
|
17
|
+
```typescript
|
|
18
|
+
export interface IBreadcrumb {
|
|
19
|
+
className?: string
|
|
20
|
+
ariaAttr: IAriaAttr
|
|
21
|
+
items: IItem[]
|
|
22
|
+
onClick: (value) => void
|
|
23
|
+
state?: string
|
|
24
|
+
}
|
|
25
|
+
```
|
|
26
|
+
|
|
27
|
+
## Variants
|
|
28
|
+
|
|
29
|
+
```
|
|
30
|
+
Default
|
|
31
|
+
|
|
32
|
+
Active
|
|
7
33
|
|
|
8
|
-
|
|
34
|
+
Inactive
|
|
9
35
|
```
|
|
10
36
|
|
|
11
|
-
|
|
37
|
+
### Default
|
|
12
38
|
|
|
13
|
-
> Breadcrumb
|
|
39
|
+
> Breadcrumb default variant
|
|
14
40
|
|
|
15
|
-
```
|
|
41
|
+
```tsx
|
|
16
42
|
<Breadcrumb ariaAttr={ariaAttr} items={items} onClick={action('onClick')} />
|
|
17
43
|
```
|
|
18
44
|
|
|
19
|
-
|
|
45
|
+
### Active
|
|
20
46
|
|
|
21
|
-
> Breadcrumb
|
|
47
|
+
> Breadcrumb active variant
|
|
22
48
|
|
|
23
|
-
```
|
|
49
|
+
```tsx
|
|
24
50
|
<Breadcrumb ariaAttr={ariaAttr} items={items} onClick={action('onClick')} state={BreadcrumbState.Active} />
|
|
25
51
|
```
|
|
26
52
|
|
|
27
|
-
|
|
53
|
+
### Inactive
|
|
28
54
|
|
|
29
|
-
> Breadcrumb
|
|
55
|
+
> Breadcrumb inactive variant
|
|
30
56
|
|
|
31
|
-
```
|
|
57
|
+
```tsx
|
|
32
58
|
<Breadcrumb ariaAttr={ariaAttr} items={items} onClick={action('onClick')} state={BreadcrumbState.Inactive} />
|
|
33
59
|
```
|