@instructure/ui-buttons 8.8.1-snapshot.3 → 8.8.1-snapshot.63

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 (93) hide show
  1. package/es/BaseButton/index.js +14 -135
  2. package/es/BaseButton/props.js +138 -0
  3. package/es/Button/index.js +4 -87
  4. package/es/Button/props.js +107 -0
  5. package/es/CloseButton/index.js +5 -93
  6. package/es/CloseButton/props.js +103 -0
  7. package/es/CondensedButton/index.js +4 -65
  8. package/es/CondensedButton/props.js +86 -0
  9. package/es/IconButton/index.js +4 -91
  10. package/es/IconButton/props.js +111 -0
  11. package/es/ToggleButton/index.js +2 -77
  12. package/es/ToggleButton/props.js +100 -0
  13. package/lib/BaseButton/index.js +14 -135
  14. package/lib/BaseButton/props.js +150 -0
  15. package/lib/Button/index.js +4 -87
  16. package/lib/Button/props.js +119 -0
  17. package/lib/CloseButton/index.js +5 -93
  18. package/lib/CloseButton/props.js +115 -0
  19. package/lib/CondensedButton/index.js +4 -65
  20. package/lib/CondensedButton/props.js +98 -0
  21. package/lib/IconButton/index.js +4 -91
  22. package/lib/IconButton/props.js +123 -0
  23. package/lib/ToggleButton/index.js +3 -79
  24. package/lib/ToggleButton/props.js +112 -0
  25. package/package.json +21 -21
  26. package/src/BaseButton/index.tsx +18 -123
  27. package/src/BaseButton/props.ts +192 -0
  28. package/src/BaseButton/styles.ts +1 -1
  29. package/src/Button/index.tsx +7 -81
  30. package/src/Button/props.ts +149 -0
  31. package/src/CloseButton/index.tsx +8 -82
  32. package/src/CloseButton/props.ts +137 -0
  33. package/src/CloseButton/styles.ts +1 -1
  34. package/src/CondensedButton/index.tsx +7 -57
  35. package/src/CondensedButton/props.ts +118 -0
  36. package/src/IconButton/index.tsx +7 -84
  37. package/src/IconButton/props.ts +154 -0
  38. package/src/ToggleButton/index.tsx +5 -68
  39. package/src/ToggleButton/props.ts +140 -0
  40. package/src/index.ts +6 -6
  41. package/types/BaseButton/index.d.ts +63 -117
  42. package/types/BaseButton/index.d.ts.map +1 -1
  43. package/types/BaseButton/{types.d.ts → props.d.ts} +14 -8
  44. package/types/BaseButton/props.d.ts.map +1 -0
  45. package/types/BaseButton/styles.d.ts +1 -1
  46. package/types/Button/index.d.ts +36 -73
  47. package/types/Button/index.d.ts.map +1 -1
  48. package/types/Button/{types.d.ts → props.d.ts} +12 -4
  49. package/types/Button/props.d.ts.map +1 -0
  50. package/types/CloseButton/index.d.ts +41 -75
  51. package/types/CloseButton/index.d.ts.map +1 -1
  52. package/types/CloseButton/props.d.ts +27 -0
  53. package/types/CloseButton/props.d.ts.map +1 -0
  54. package/types/CloseButton/styles.d.ts +1 -1
  55. package/types/CondensedButton/index.d.ts +28 -55
  56. package/types/CondensedButton/index.d.ts.map +1 -1
  57. package/types/CondensedButton/props.d.ts +24 -0
  58. package/types/CondensedButton/props.d.ts.map +1 -0
  59. package/types/IconButton/index.d.ts +38 -76
  60. package/types/IconButton/index.d.ts.map +1 -1
  61. package/types/IconButton/{types.d.ts → props.d.ts} +11 -3
  62. package/types/IconButton/props.d.ts.map +1 -0
  63. package/types/ToggleButton/index.d.ts +34 -65
  64. package/types/ToggleButton/index.d.ts.map +1 -1
  65. package/types/ToggleButton/{types.d.ts → props.d.ts} +10 -3
  66. package/types/ToggleButton/props.d.ts.map +1 -0
  67. package/types/index.d.ts +6 -6
  68. package/es/BaseButton/types.js +0 -1
  69. package/es/Button/types.js +0 -1
  70. package/es/CloseButton/types.js +0 -1
  71. package/es/CondensedButton/types.js +0 -1
  72. package/es/IconButton/types.js +0 -1
  73. package/es/ToggleButton/types.js +0 -1
  74. package/lib/BaseButton/types.js +0 -1
  75. package/lib/Button/types.js +0 -1
  76. package/lib/CloseButton/types.js +0 -1
  77. package/lib/CondensedButton/types.js +0 -1
  78. package/lib/IconButton/types.js +0 -1
  79. package/lib/ToggleButton/types.js +0 -1
  80. package/src/BaseButton/types.ts +0 -57
  81. package/src/Button/types.ts +0 -44
  82. package/src/CloseButton/types.ts +0 -45
  83. package/src/CondensedButton/types.ts +0 -40
  84. package/src/IconButton/types.ts +0 -45
  85. package/src/ToggleButton/types.ts +0 -48
  86. package/types/BaseButton/types.d.ts.map +0 -1
  87. package/types/Button/types.d.ts.map +0 -1
  88. package/types/CloseButton/types.d.ts +0 -22
  89. package/types/CloseButton/types.d.ts.map +0 -1
  90. package/types/CondensedButton/types.d.ts +0 -16
  91. package/types/CondensedButton/types.d.ts.map +0 -1
  92. package/types/IconButton/types.d.ts.map +0 -1
  93. package/types/ToggleButton/types.d.ts.map +0 -1
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/ToggleButton/index.tsx"],"names":[],"mappings":"AAwBA,OAAc,EAAE,SAAS,EAAE,MAAM,OAAO,CAAA;AACxC,OAAO,SAAS,MAAM,YAAY,CAAA;AASlC,OAAO,EAAE,iBAAiB,EAAE,MAAM,SAAS,CAAA;AAE3C;;;;GAIG;AAEH,cACM,YAAa,SAAQ,SAAS,CAAC,iBAAiB,CAAC;IACrD,MAAM,CAAC,QAAQ,CAAC,WAAW,kBAAiB;IAE5C,MAAM,CAAC,SAAS;QACd;;WAEG;;QAEH;;WAEG;;QAGH;;WAEG;;QAGH;;WAEG;;QAEH;;WAEG;;QAEH;;WAEG;;QAEH;;WAEG;;QAEH;;WAEG;;QAEH;;WAEG;;QAEH;;WAEG;;QAEH;;WAEG;;QAEH;;WAEG;;QAEH;;WAEG;;QAEH;;;;WAIG;;MAEJ;IAED,MAAM,CAAC,YAAY;;;;;;;;;;;;MAclB;gBAGW,KAAK,KAAA;IAQjB,IAAI,gBAAgB,QAKnB;IAED,MAAM;CAqDP;AAED,OAAO,EAAE,YAAY,EAAE,CAAA;AACvB,eAAe,YAAY,CAAA"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/ToggleButton/index.tsx"],"names":[],"mappings":"AAwBA,OAAO,KAAK,EAAE,EAAE,SAAS,EAAE,MAAM,OAAO,CAAA;AAUxC,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,SAAS,CAAA;AAEhD;;;;GAIG;AAEH,cACM,YAAa,SAAQ,SAAS,CAAC,iBAAiB,CAAC;IACrD,MAAM,CAAC,QAAQ,CAAC,WAAW,kBAAiB;IAE5C,MAAM,CAAC,SAAS;;;;;;;;;;;;;;;OAAY;IAC5B,MAAM,CAAC,YAAY;;;;;;;;;;;;;;;SAAe;IAClC,MAAM,CAAC,YAAY;;;;;;;;;;MAYlB;gBAGW,KAAK,KAAA;IAQjB,IAAI,gBAAgB,QAKnB;IAED,MAAM;CAqDP;AAED,OAAO,EAAE,YAAY,EAAE,CAAA;AACvB,eAAe,YAAY,CAAA"}
@@ -1,7 +1,7 @@
1
1
  import React from 'react';
2
- import { AsElementType } from '@instructure/shared-types';
2
+ import type { AsElementType, PropValidators } from '@instructure/shared-types';
3
3
  import type { PlacementPropValues, PositionConstraint, PositionMountNode } from '@instructure/ui-position';
4
- export declare type ToggleButtonProps = {
4
+ declare type ToggleButtonOwnProps = {
5
5
  screenReaderLabel: string;
6
6
  renderTooltipContent: React.ReactNode | ((...args: any[]) => any);
7
7
  renderIcon: React.ReactNode | ((...args: any[]) => any);
@@ -17,4 +17,11 @@ export declare type ToggleButtonProps = {
17
17
  placement?: PlacementPropValues;
18
18
  constrain?: PositionConstraint;
19
19
  };
20
- //# sourceMappingURL=types.d.ts.map
20
+ declare type PropKeys = keyof ToggleButtonOwnProps;
21
+ declare type AllowedPropKeys = Readonly<Array<PropKeys>>;
22
+ declare type ToggleButtonProps = ToggleButtonOwnProps;
23
+ declare const propTypes: PropValidators<PropKeys>;
24
+ declare const allowedProps: AllowedPropKeys;
25
+ export type { ToggleButtonProps };
26
+ export { propTypes, allowedProps };
27
+ //# sourceMappingURL=props.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"props.d.ts","sourceRoot":"","sources":["../../src/ToggleButton/props.ts"],"names":[],"mappings":"AAwBA,OAAO,KAAK,MAA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DvC,CAAA;AAED,QAAA,MAAM,YAAY,EAAE,eAenB,CAAA;AAED,YAAY,EAAE,iBAAiB,EAAE,CAAA;AACjC,OAAO,EAAE,SAAS,EAAE,YAAY,EAAE,CAAA"}
package/types/index.d.ts CHANGED
@@ -4,10 +4,10 @@ export { CloseButton } from './CloseButton';
4
4
  export { CondensedButton } from './CondensedButton';
5
5
  export { IconButton } from './IconButton';
6
6
  export { ToggleButton } from './ToggleButton';
7
- export type { BaseButtonProps } from './BaseButton/types';
8
- export type { ButtonProps } from './Button/types';
9
- export type { CloseButtonProps } from './CloseButton/types';
10
- export type { CondensedButtonProps } from './CondensedButton/types';
11
- export type { IconButtonProps } from './IconButton/types';
12
- export type { ToggleButtonProps } from './ToggleButton/types';
7
+ export type { BaseButtonProps } from './BaseButton/props';
8
+ export type { ButtonProps } from './Button/props';
9
+ export type { CloseButtonProps } from './CloseButton/props';
10
+ export type { CondensedButtonProps } from './CondensedButton/props';
11
+ export type { IconButtonProps } from './IconButton/props';
12
+ export type { ToggleButtonProps } from './ToggleButton/props';
13
13
  //# sourceMappingURL=index.d.ts.map
@@ -1 +0,0 @@
1
- export {};
@@ -1 +0,0 @@
1
- export {};
@@ -1 +0,0 @@
1
- export {};
@@ -1 +0,0 @@
1
- export {};
@@ -1 +0,0 @@
1
- export {};
@@ -1 +0,0 @@
1
- export {};
@@ -1 +0,0 @@
1
- "use strict";
@@ -1 +0,0 @@
1
- "use strict";
@@ -1 +0,0 @@
1
- "use strict";
@@ -1 +0,0 @@
1
- "use strict";
@@ -1 +0,0 @@
1
- "use strict";
@@ -1 +0,0 @@
1
- "use strict";
@@ -1,57 +0,0 @@
1
- /*
2
- * The MIT License (MIT)
3
- *
4
- * Copyright (c) 2015 - present Instructure, Inc.
5
- *
6
- * Permission is hereby granted, free of charge, to any person obtaining a copy
7
- * of this software and associated documentation files (the "Software"), to deal
8
- * in the Software without restriction, including without limitation the rights
9
- * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
10
- * copies of the Software, and to permit persons to whom the Software is
11
- * furnished to do so, subject to the following conditions:
12
- *
13
- * The above copyright notice and this permission notice shall be included in all
14
- * copies or substantial portions of the Software.
15
- *
16
- * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
17
- * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
18
- * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
19
- * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
20
- * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
21
- * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
22
- * SOFTWARE.
23
- */
24
-
25
- import { AsElementType } from '@instructure/shared-types'
26
- import type { InteractionType } from '@instructure/ui-react-utils'
27
- import type { Spacing } from '@instructure/emotion'
28
-
29
- export type BaseButtonProps = {
30
- makeStyles?: (...args: any[]) => any
31
- styles?: any
32
- type?: 'button' | 'submit' | 'reset'
33
- size?: 'small' | 'medium' | 'large'
34
- elementRef?: (...args: any[]) => any
35
- as?: AsElementType
36
- interaction?: InteractionType
37
- color?: 'primary' | 'primary-inverse' | 'secondary' | 'success' | 'danger'
38
- focusColor?: 'info' | 'inverse'
39
- display?: 'inline-block' | 'block'
40
- textAlign?: 'start' | 'center'
41
- shape?: 'rectangle' | 'circle'
42
- withBackground?: boolean
43
- withBorder?: boolean
44
- isCondensed?: boolean
45
- margin?: Spacing
46
- cursor?: string
47
- href?: string
48
- onClick?: (...args: any[]) => any
49
- onKeyDown?: (...args: any[]) => any
50
- renderIcon?: React.ReactNode | ((...args: any[]) => any)
51
- tabIndex?: number | string
52
- }
53
-
54
- export type BaseButtonStyleProps = {
55
- isDisabled: boolean
56
- hasOnlyIconVisible: boolean
57
- }
@@ -1,44 +0,0 @@
1
- /*
2
- * The MIT License (MIT)
3
- *
4
- * Copyright (c) 2015 - present Instructure, Inc.
5
- *
6
- * Permission is hereby granted, free of charge, to any person obtaining a copy
7
- * of this software and associated documentation files (the "Software"), to deal
8
- * in the Software without restriction, including without limitation the rights
9
- * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
10
- * copies of the Software, and to permit persons to whom the Software is
11
- * furnished to do so, subject to the following conditions:
12
- *
13
- * The above copyright notice and this permission notice shall be included in all
14
- * copies or substantial portions of the Software.
15
- *
16
- * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
17
- * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
18
- * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
19
- * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
20
- * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
21
- * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
22
- * SOFTWARE.
23
- */
24
-
25
- import { AsElementType } from '@instructure/shared-types'
26
- import type { Spacing } from '@instructure/emotion'
27
- import React from 'react'
28
-
29
- export type ButtonProps = {
30
- type?: 'button' | 'submit' | 'reset'
31
- size?: 'small' | 'medium' | 'large'
32
- elementRef?: (...args: any[]) => any
33
- as?: AsElementType
34
- interaction?: 'enabled' | 'disabled' | 'readonly'
35
- color?: 'primary' | 'primary-inverse' | 'secondary' | 'success' | 'danger'
36
- focusColor?: 'info' | 'inverse'
37
- display?: 'inline-block' | 'block'
38
- textAlign?: 'start' | 'center'
39
- withBackground?: boolean
40
- margin?: Spacing
41
- cursor?: string
42
- href?: string
43
- renderIcon?: React.ReactNode | ((...args: any[]) => any)
44
- }
@@ -1,45 +0,0 @@
1
- /*
2
- * The MIT License (MIT)
3
- *
4
- * Copyright (c) 2015 - present Instructure, Inc.
5
- *
6
- * Permission is hereby granted, free of charge, to any person obtaining a copy
7
- * of this software and associated documentation files (the "Software"), to deal
8
- * in the Software without restriction, including without limitation the rights
9
- * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
10
- * copies of the Software, and to permit persons to whom the Software is
11
- * furnished to do so, subject to the following conditions:
12
- *
13
- * The above copyright notice and this permission notice shall be included in all
14
- * copies or substantial portions of the Software.
15
- *
16
- * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
17
- * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
18
- * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
19
- * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
20
- * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
21
- * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
22
- * SOFTWARE.
23
- */
24
-
25
- import type { Spacing } from '@instructure/emotion'
26
- import { AsElementType } from '@instructure/shared-types'
27
-
28
- export type CloseButtonProps = {
29
- makeStyles?: (...args: any[]) => any
30
- styles?: any
31
- screenReaderLabel: string | React.ReactNode
32
- color?: 'primary' | 'primary-inverse'
33
- interaction?: 'enabled' | 'disabled' | 'readonly'
34
- elementRef?: (...args: any[]) => any
35
- size?: 'small' | 'medium' | 'large'
36
- onClick?: (...args: any[]) => any
37
- margin?: Spacing
38
- placement?: 'start' | 'end' | 'static'
39
- offset?: 'none' | 'x-small' | 'small' | 'medium'
40
- type?: 'button' | 'submit' | 'reset'
41
- as?: AsElementType
42
- href?: string
43
- cursor?: string
44
- tabIndex?: number | string
45
- }
@@ -1,40 +0,0 @@
1
- /*
2
- * The MIT License (MIT)
3
- *
4
- * Copyright (c) 2015 - present Instructure, Inc.
5
- *
6
- * Permission is hereby granted, free of charge, to any person obtaining a copy
7
- * of this software and associated documentation files (the "Software"), to deal
8
- * in the Software without restriction, including without limitation the rights
9
- * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
10
- * copies of the Software, and to permit persons to whom the Software is
11
- * furnished to do so, subject to the following conditions:
12
- *
13
- * The above copyright notice and this permission notice shall be included in all
14
- * copies or substantial portions of the Software.
15
- *
16
- * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
17
- * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
18
- * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
19
- * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
20
- * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
21
- * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
22
- * SOFTWARE.
23
- */
24
-
25
- import { AsElementType } from '@instructure/shared-types'
26
- import type { Spacing } from '@instructure/emotion'
27
- import React from 'react'
28
-
29
- export type CondensedButtonProps = {
30
- type?: 'button' | 'submit' | 'reset'
31
- size?: 'small' | 'medium' | 'large'
32
- elementRef?: (...args: any[]) => any
33
- as?: AsElementType
34
- interaction?: 'enabled' | 'disabled' | 'readonly'
35
- color?: 'primary' | 'primary-inverse'
36
- margin?: Spacing
37
- cursor?: string
38
- href?: string
39
- renderIcon?: React.ReactNode | ((...args: any[]) => any)
40
- }
@@ -1,45 +0,0 @@
1
- /*
2
- * The MIT License (MIT)
3
- *
4
- * Copyright (c) 2015 - present Instructure, Inc.
5
- *
6
- * Permission is hereby granted, free of charge, to any person obtaining a copy
7
- * of this software and associated documentation files (the "Software"), to deal
8
- * in the Software without restriction, including without limitation the rights
9
- * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
10
- * copies of the Software, and to permit persons to whom the Software is
11
- * furnished to do so, subject to the following conditions:
12
- *
13
- * The above copyright notice and this permission notice shall be included in all
14
- * copies or substantial portions of the Software.
15
- *
16
- * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
17
- * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
18
- * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
19
- * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
20
- * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
21
- * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
22
- * SOFTWARE.
23
- */
24
-
25
- import React from 'react'
26
- import { AsElementType } from '@instructure/shared-types'
27
- import type { Spacing } from '@instructure/emotion'
28
-
29
- export type IconButtonProps = {
30
- renderIcon?: React.ReactNode | ((...args: any[]) => any)
31
- screenReaderLabel: string
32
- type?: 'button' | 'submit' | 'reset'
33
- size?: 'small' | 'medium' | 'large'
34
- elementRef?: (...args: any[]) => any
35
- as?: AsElementType
36
- interaction?: 'enabled' | 'disabled' | 'readonly'
37
- color?: 'primary' | 'primary-inverse' | 'secondary' | 'success' | 'danger'
38
- focusColor?: 'info' | 'inverse'
39
- shape?: 'rectangle' | 'circle'
40
- withBackground?: boolean
41
- withBorder?: boolean
42
- margin?: Spacing
43
- cursor?: string
44
- href?: string
45
- }
@@ -1,48 +0,0 @@
1
- /*
2
- * The MIT License (MIT)
3
- *
4
- * Copyright (c) 2015 - present Instructure, Inc.
5
- *
6
- * Permission is hereby granted, free of charge, to any person obtaining a copy
7
- * of this software and associated documentation files (the "Software"), to deal
8
- * in the Software without restriction, including without limitation the rights
9
- * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
10
- * copies of the Software, and to permit persons to whom the Software is
11
- * furnished to do so, subject to the following conditions:
12
- *
13
- * The above copyright notice and this permission notice shall be included in all
14
- * copies or substantial portions of the Software.
15
- *
16
- * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
17
- * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
18
- * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
19
- * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
20
- * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
21
- * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
22
- * SOFTWARE.
23
- */
24
-
25
- import React from 'react'
26
- import { AsElementType } from '@instructure/shared-types'
27
- import type {
28
- PlacementPropValues,
29
- PositionConstraint,
30
- PositionMountNode
31
- } from '@instructure/ui-position'
32
-
33
- export type ToggleButtonProps = {
34
- screenReaderLabel: string
35
- renderTooltipContent: React.ReactNode | ((...args: any[]) => any)
36
- renderIcon: React.ReactNode | ((...args: any[]) => any)
37
- status: 'pressed' | 'unpressed'
38
- as?: AsElementType
39
- interaction?: 'enabled' | 'disabled' | 'readonly'
40
- size?: 'small' | 'medium' | 'large'
41
- elementRef?: (...args: any[]) => any
42
- onClick?: (...args: any[]) => any
43
- color?: string
44
- isShowingTooltip?: boolean
45
- mountNode?: PositionMountNode
46
- placement?: PlacementPropValues
47
- constrain?: PositionConstraint
48
- }
@@ -1 +0,0 @@
1
- {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../src/BaseButton/types.ts"],"names":[],"mappings":";AAwBA,OAAO,EAAE,aAAa,EAAE,MAAM,2BAA2B,CAAA;AACzD,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,6BAA6B,CAAA;AAClE,OAAO,KAAK,EAAE,OAAO,E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1
- /// <reference types="react" />
2
- import type { Spacing } from '@instructure/emotion';
3
- import { AsElementType } from '@instructure/shared-types';
4
- export declare type CloseButtonProps = {
5
- makeStyles?: (...args: any[]) => any;
6
- styles?: any;
7
- screenReaderLabel: string | React.ReactNode;
8
- color?: 'primary' | 'primary-inverse';
9
- interaction?: 'enabled' | 'disabled' | 'readonly';
10
- elementRef?: (...args: any[]) => any;
11
- size?: 'small' | 'medium' | 'large';
12
- onClick?: (...args: any[]) => any;
13
- margin?: Spacing;
14
- placement?: 'start' | 'end' | 'static';
15
- offset?: 'none' | 'x-small' | 'small' | 'medium';
16
- type?: 'button' | 'submit' | 'reset';
17
- as?: AsElementType;
18
- href?: string;
19
- cursor?: string;
20
- tabIndex?: number | string;
21
- };
22
- //# sourceMappingURL=types.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../src/CloseButton/types.ts"],"names":[],"mappings":";AAwBA,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,sBAAsB,CAAA;AACnD,OAAO,EAAE,aAAa,EAAE,MAAM,2BAA2B,CAAA;AAEzD,oBAAY,gBAAgB,GAAG;IAC7B,UAAU,CAAC,EAAE,CAAC,GAAG,IAAI,EAAE,GAAG,EAAE,KAAK,GAAG,CAAA;IACpC,MAAM,CAAC,EAAE,GAAG,CAAA;IACZ,iBAAiB,EAAE,MAAM,GAAG,KAAK,CAAC,SAAS,CAAA;IAC3C,KAAK,CAAC,EAAE,SAAS,GAAG,iBAAiB,CAAA;IACrC,WAAW,CAAC,EAAE,SAAS,GAAG,UAAU,GAAG,UAAU,CAAA;IACjD,UAAU,CAAC,EAAE,CAAC,GAAG,IAAI,EAAE,GAAG,EAAE,KAAK,GAAG,CAAA;IACpC,IAAI,CAAC,EAAE,OAAO,GAAG,QAAQ,GAAG,OAAO,CAAA;IACnC,OAAO,CAAC,EAAE,CAAC,GAAG,IAAI,EAAE,GAAG,EAAE,KAAK,GAAG,CAAA;IACjC,MAAM,CAAC,EAAE,OAAO,CAAA;IAChB,SAAS,CAAC,EAAE,OAAO,GAAG,KAAK,GAAG,QAAQ,CAAA;IACtC,MAAM,CAAC,EAAE,MAAM,GAAG,SAAS,GAAG,OAAO,GAAG,QAAQ,CAAA;IAChD,IAAI,CAAC,EAAE,QAAQ,GAAG,QAAQ,GAAG,OAAO,CAAA;IACpC,EAAE,CAAC,EAAE,aAAa,CAAA;IAClB,IAAI,CAAC,EAAE,MAAM,CAAA;IACb,MAAM,CAAC,EAAE,MAAM,CAAA;IACf,QAAQ,CAAC,EAAE,MAAM,GAAG,MAAM,CAAA;CAC3B,CAAA"}
@@ -1,16 +0,0 @@
1
- import { AsElementType } from '@instructure/shared-types';
2
- import type { Spacing } from '@instructure/emotion';
3
- import React from 'react';
4
- export declare type CondensedButtonProps = {
5
- type?: 'button' | 'submit' | 'reset';
6
- size?: 'small' | 'medium' | 'large';
7
- elementRef?: (...args: any[]) => any;
8
- as?: AsElementType;
9
- interaction?: 'enabled' | 'disabled' | 'readonly';
10
- color?: 'primary' | 'primary-inverse';
11
- margin?: Spacing;
12
- cursor?: string;
13
- href?: string;
14
- renderIcon?: React.ReactNode | ((...args: any[]) => any);
15
- };
16
- //# sourceMappingURL=types.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../src/CondensedButton/types.ts"],"names":[],"mappings":"AAwBA,OAAO,EAAE,aAAa,EAAE,MAAM,2BAA2B,CAAA;AACzD,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,sBAAsB,CAAA;AACnD,OAAO,KAAK,MAAM,OAAO,CAAA;AAEzB,oBAAY,oBAAoB,GAAG;IACjC,IAAI,CAAC,EAAE,QAAQ,GAAG,QAAQ,GAAG,OAAO,CAAA;IACpC,IAAI,CAAC,EAAE,OAAO,GAAG,QAAQ,GAAG,OAAO,CAAA;IACnC,UAAU,CAAC,EAAE,CAAC,GAAG,IAAI,EAAE,GAAG,EAAE,KAAK,GAA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