@fluentui-react-native/radio-group 0.22.3 → 0.22.5
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/.cache/tsconfig.tsbuildinfo +1 -0
- package/CHANGELOG.md +52 -0
- package/jest.config.cjs +1 -0
- package/lib/Radio/Radio.d.ts +1 -1
- package/lib/Radio/Radio.d.ts.map +1 -1
- package/lib/Radio/Radio.ios.d.ts +1 -1
- package/lib/Radio/Radio.ios.d.ts.map +1 -1
- package/lib/Radio/Radio.ios.js +2 -4
- package/lib/Radio/Radio.ios.js.map +1 -1
- package/lib/Radio/Radio.js +2 -4
- package/lib/Radio/Radio.js.map +1 -1
- package/lib/Radio/__tests__/RadioExperimental.test.js.map +1 -1
- package/lib/Radio/useRadio.d.ts.map +1 -1
- package/lib/Radio/useRadio.js.map +1 -1
- package/lib/Radio/useRadio.win32.d.ts.map +1 -1
- package/lib/Radio/useRadio.win32.js +6 -7
- package/lib/Radio/useRadio.win32.js.map +1 -1
- package/lib/RadioGroup/RadioGroup.d.ts +1 -1
- package/lib/RadioGroup/RadioGroup.d.ts.map +1 -1
- package/lib/RadioGroup/RadioGroup.js +1 -2
- package/lib/RadioGroup/RadioGroup.js.map +1 -1
- package/lib/RadioGroup/__tests__/RadioGroupExperimental.test.js +6 -18
- package/lib/RadioGroup/__tests__/RadioGroupExperimental.test.js.map +1 -1
- package/lib/RadioGroup/radioGroupContext.js +6 -6
- package/lib/RadioGroup/radioGroupContext.js.map +1 -1
- package/lib/RadioGroup/useRadioGroup.d.ts.map +1 -1
- package/lib/RadioGroup/useRadioGroup.js.map +1 -1
- package/lib/RadioGroup/useRadioGroupContextValue.d.ts +2 -1
- package/lib/RadioGroup/useRadioGroupContextValue.d.ts.map +1 -1
- package/lib/RadioGroup/useRadioGroupContextValue.js.map +1 -1
- package/lib/legacy/MacOSRadioButtonNativeComponent.d.ts.map +1 -1
- package/lib/legacy/RadioButton.d.ts.map +1 -1
- package/lib/legacy/RadioButton.js +1 -2
- package/lib/legacy/RadioButton.js.map +1 -1
- package/lib/legacy/RadioButton.macos.d.ts.map +1 -1
- package/lib/legacy/RadioButton.macos.js.map +1 -1
- package/lib/legacy/RadioButton.win32.d.ts.map +1 -1
- package/lib/legacy/RadioButton.win32.js +7 -9
- package/lib/legacy/RadioButton.win32.js.map +1 -1
- package/lib/legacy/RadioGroup.d.ts.map +1 -1
- package/lib/legacy/RadioGroup.js +3 -5
- package/lib/legacy/RadioGroup.js.map +1 -1
- package/lib/legacy/__tests__/RadioButton.test.js.map +1 -1
- package/lib/legacy/__tests__/RadioButtonGroup.test.js +2 -6
- package/lib/legacy/__tests__/RadioButtonGroup.test.js.map +1 -1
- package/package.json +25 -30
- package/src/Radio/useRadio.win32.ts +7 -6
- package/src/legacy/RadioButton.win32.tsx +7 -6
- package/tsconfig.json +53 -3
- package/babel.config.js +0 -1
- package/jest.config.js +0 -2
- package/lib-commonjs/Radio/Radio.d.ts +0 -13
- package/lib-commonjs/Radio/Radio.d.ts.map +0 -1
- package/lib-commonjs/Radio/Radio.ios.d.ts +0 -13
- package/lib-commonjs/Radio/Radio.ios.d.ts.map +0 -1
- package/lib-commonjs/Radio/Radio.ios.js +0 -55
- package/lib-commonjs/Radio/Radio.ios.js.map +0 -1
- package/lib-commonjs/Radio/Radio.js +0 -54
- package/lib-commonjs/Radio/Radio.js.map +0 -1
- package/lib-commonjs/Radio/Radio.styling.d.ts +0 -5
- package/lib-commonjs/Radio/Radio.styling.d.ts.map +0 -1
- package/lib-commonjs/Radio/Radio.styling.js +0 -98
- package/lib-commonjs/Radio/Radio.styling.js.map +0 -1
- package/lib-commonjs/Radio/Radio.types.d.ts +0 -186
- package/lib-commonjs/Radio/Radio.types.d.ts.map +0 -1
- package/lib-commonjs/Radio/Radio.types.js +0 -5
- package/lib-commonjs/Radio/Radio.types.js.map +0 -1
- package/lib-commonjs/Radio/RadioTokens.android.d.ts +0 -5
- package/lib-commonjs/Radio/RadioTokens.android.d.ts.map +0 -1
- package/lib-commonjs/Radio/RadioTokens.android.js +0 -53
- package/lib-commonjs/Radio/RadioTokens.android.js.map +0 -1
- package/lib-commonjs/Radio/RadioTokens.d.ts +0 -5
- package/lib-commonjs/Radio/RadioTokens.d.ts.map +0 -1
- package/lib-commonjs/Radio/RadioTokens.ios.d.ts +0 -5
- package/lib-commonjs/Radio/RadioTokens.ios.d.ts.map +0 -1
- package/lib-commonjs/Radio/RadioTokens.ios.js +0 -51
- package/lib-commonjs/Radio/RadioTokens.ios.js.map +0 -1
- package/lib-commonjs/Radio/RadioTokens.js +0 -88
- package/lib-commonjs/Radio/RadioTokens.js.map +0 -1
- package/lib-commonjs/Radio/RadioTokens.win32.d.ts +0 -5
- package/lib-commonjs/Radio/RadioTokens.win32.d.ts.map +0 -1
- package/lib-commonjs/Radio/RadioTokens.win32.js +0 -102
- package/lib-commonjs/Radio/RadioTokens.win32.js.map +0 -1
- package/lib-commonjs/Radio/__tests__/RadioExperimental.test.d.ts +0 -2
- package/lib-commonjs/Radio/__tests__/RadioExperimental.test.d.ts.map +0 -1
- package/lib-commonjs/Radio/__tests__/RadioExperimental.test.js +0 -56
- package/lib-commonjs/Radio/__tests__/RadioExperimental.test.js.map +0 -1
- package/lib-commonjs/Radio/useRadio.d.ts +0 -3
- package/lib-commonjs/Radio/useRadio.d.ts.map +0 -1
- package/lib-commonjs/Radio/useRadio.js +0 -121
- package/lib-commonjs/Radio/useRadio.js.map +0 -1
- package/lib-commonjs/Radio/useRadio.win32.d.ts +0 -3
- package/lib-commonjs/Radio/useRadio.win32.d.ts.map +0 -1
- package/lib-commonjs/Radio/useRadio.win32.js +0 -180
- package/lib-commonjs/Radio/useRadio.win32.js.map +0 -1
- package/lib-commonjs/RadioGroup/RadioGroup.d.ts +0 -12
- package/lib-commonjs/RadioGroup/RadioGroup.d.ts.map +0 -1
- package/lib-commonjs/RadioGroup/RadioGroup.js +0 -59
- package/lib-commonjs/RadioGroup/RadioGroup.js.map +0 -1
- package/lib-commonjs/RadioGroup/RadioGroup.styling.d.ts +0 -5
- package/lib-commonjs/RadioGroup/RadioGroup.styling.d.ts.map +0 -1
- package/lib-commonjs/RadioGroup/RadioGroup.styling.js +0 -52
- package/lib-commonjs/RadioGroup/RadioGroup.styling.js.map +0 -1
- package/lib-commonjs/RadioGroup/RadioGroup.types.d.ts +0 -134
- package/lib-commonjs/RadioGroup/RadioGroup.types.d.ts.map +0 -1
- package/lib-commonjs/RadioGroup/RadioGroup.types.js +0 -5
- package/lib-commonjs/RadioGroup/RadioGroup.types.js.map +0 -1
- package/lib-commonjs/RadioGroup/RadioGroupTokens.android.d.ts +0 -3
- package/lib-commonjs/RadioGroup/RadioGroupTokens.android.d.ts.map +0 -1
- package/lib-commonjs/RadioGroup/RadioGroupTokens.android.js +0 -6
- package/lib-commonjs/RadioGroup/RadioGroupTokens.android.js.map +0 -1
- package/lib-commonjs/RadioGroup/RadioGroupTokens.d.ts +0 -5
- package/lib-commonjs/RadioGroup/RadioGroupTokens.d.ts.map +0 -1
- package/lib-commonjs/RadioGroup/RadioGroupTokens.ios.d.ts +0 -2
- package/lib-commonjs/RadioGroup/RadioGroupTokens.ios.d.ts.map +0 -1
- package/lib-commonjs/RadioGroup/RadioGroupTokens.ios.js +0 -6
- package/lib-commonjs/RadioGroup/RadioGroupTokens.ios.js.map +0 -1
- package/lib-commonjs/RadioGroup/RadioGroupTokens.js +0 -19
- package/lib-commonjs/RadioGroup/RadioGroupTokens.js.map +0 -1
- package/lib-commonjs/RadioGroup/RadioGroupTokens.mobile.d.ts +0 -5
- package/lib-commonjs/RadioGroup/RadioGroupTokens.mobile.d.ts.map +0 -1
- package/lib-commonjs/RadioGroup/RadioGroupTokens.mobile.js +0 -20
- package/lib-commonjs/RadioGroup/RadioGroupTokens.mobile.js.map +0 -1
- package/lib-commonjs/RadioGroup/__tests__/RadioGroupExperimental.test.d.ts +0 -2
- package/lib-commonjs/RadioGroup/__tests__/RadioGroupExperimental.test.d.ts.map +0 -1
- package/lib-commonjs/RadioGroup/__tests__/RadioGroupExperimental.test.js +0 -104
- package/lib-commonjs/RadioGroup/__tests__/RadioGroupExperimental.test.js.map +0 -1
- package/lib-commonjs/RadioGroup/radioGroupContext.d.ts +0 -10
- package/lib-commonjs/RadioGroup/radioGroupContext.d.ts.map +0 -1
- package/lib-commonjs/RadioGroup/radioGroupContext.js +0 -59
- package/lib-commonjs/RadioGroup/radioGroupContext.js.map +0 -1
- package/lib-commonjs/RadioGroup/useRadioGroup.d.ts +0 -3
- package/lib-commonjs/RadioGroup/useRadioGroup.d.ts.map +0 -1
- package/lib-commonjs/RadioGroup/useRadioGroup.js +0 -108
- package/lib-commonjs/RadioGroup/useRadioGroup.js.map +0 -1
- package/lib-commonjs/RadioGroup/useRadioGroupContextValue.d.ts +0 -3
- package/lib-commonjs/RadioGroup/useRadioGroupContextValue.d.ts.map +0 -1
- package/lib-commonjs/RadioGroup/useRadioGroupContextValue.js +0 -8
- package/lib-commonjs/RadioGroup/useRadioGroupContextValue.js.map +0 -1
- package/lib-commonjs/index.d.ts +0 -18
- package/lib-commonjs/index.d.ts.map +0 -1
- package/lib-commonjs/index.js +0 -32
- package/lib-commonjs/index.js.map +0 -1
- package/lib-commonjs/legacy/MacOSRadioButtonNativeComponent.d.ts +0 -17
- package/lib-commonjs/legacy/MacOSRadioButtonNativeComponent.d.ts.map +0 -1
- package/lib-commonjs/legacy/MacOSRadioButtonNativeComponent.js +0 -13
- package/lib-commonjs/legacy/MacOSRadioButtonNativeComponent.js.map +0 -1
- package/lib-commonjs/legacy/RadioButton.d.ts +0 -4
- package/lib-commonjs/legacy/RadioButton.d.ts.map +0 -1
- package/lib-commonjs/legacy/RadioButton.js +0 -135
- package/lib-commonjs/legacy/RadioButton.js.map +0 -1
- package/lib-commonjs/legacy/RadioButton.macos.d.ts +0 -4
- package/lib-commonjs/legacy/RadioButton.macos.d.ts.map +0 -1
- package/lib-commonjs/legacy/RadioButton.macos.js +0 -106
- package/lib-commonjs/legacy/RadioButton.macos.js.map +0 -1
- package/lib-commonjs/legacy/RadioButton.settings.d.ts +0 -5
- package/lib-commonjs/legacy/RadioButton.settings.d.ts.map +0 -1
- package/lib-commonjs/legacy/RadioButton.settings.js +0 -98
- package/lib-commonjs/legacy/RadioButton.settings.js.map +0 -1
- package/lib-commonjs/legacy/RadioButton.types.d.ts +0 -62
- package/lib-commonjs/legacy/RadioButton.types.d.ts.map +0 -1
- package/lib-commonjs/legacy/RadioButton.types.js +0 -5
- package/lib-commonjs/legacy/RadioButton.types.js.map +0 -1
- package/lib-commonjs/legacy/RadioButton.win32.d.ts +0 -4
- package/lib-commonjs/legacy/RadioButton.win32.d.ts.map +0 -1
- package/lib-commonjs/legacy/RadioButton.win32.js +0 -192
- package/lib-commonjs/legacy/RadioButton.win32.js.map +0 -1
- package/lib-commonjs/legacy/RadioGroup.d.ts +0 -7
- package/lib-commonjs/legacy/RadioGroup.d.ts.map +0 -1
- package/lib-commonjs/legacy/RadioGroup.js +0 -135
- package/lib-commonjs/legacy/RadioGroup.js.map +0 -1
- package/lib-commonjs/legacy/RadioGroup.settings.d.ts +0 -4
- package/lib-commonjs/legacy/RadioGroup.settings.d.ts.map +0 -1
- package/lib-commonjs/legacy/RadioGroup.settings.js +0 -28
- package/lib-commonjs/legacy/RadioGroup.settings.js.map +0 -1
- package/lib-commonjs/legacy/RadioGroup.types.d.ts +0 -96
- package/lib-commonjs/legacy/RadioGroup.types.d.ts.map +0 -1
- package/lib-commonjs/legacy/RadioGroup.types.js +0 -5
- package/lib-commonjs/legacy/RadioGroup.types.js.map +0 -1
- package/lib-commonjs/legacy/__tests__/RadioButton.test.d.ts +0 -2
- package/lib-commonjs/legacy/__tests__/RadioButton.test.d.ts.map +0 -1
- package/lib-commonjs/legacy/__tests__/RadioButton.test.js +0 -49
- package/lib-commonjs/legacy/__tests__/RadioButton.test.js.map +0 -1
- package/lib-commonjs/legacy/__tests__/RadioButtonGroup.test.d.ts +0 -2
- package/lib-commonjs/legacy/__tests__/RadioButtonGroup.test.d.ts.map +0 -1
- package/lib-commonjs/legacy/__tests__/RadioButtonGroup.test.js +0 -61
- package/lib-commonjs/legacy/__tests__/RadioButtonGroup.test.js.map +0 -1
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@fluentui-react-native/radio-group",
|
|
3
|
-
"version": "0.22.
|
|
3
|
+
"version": "0.22.5",
|
|
4
4
|
"description": "A cross-platform Radio Group component using the Fluent Design System",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"author": "",
|
|
@@ -9,54 +9,48 @@
|
|
|
9
9
|
"url": "https://github.com/microsoft/fluentui-react-native.git",
|
|
10
10
|
"directory": "packages/components/RadioGroup"
|
|
11
11
|
},
|
|
12
|
+
"type": "module",
|
|
12
13
|
"sideEffects": false,
|
|
13
|
-
"main": "lib
|
|
14
|
+
"main": "lib/index.js",
|
|
14
15
|
"module": "lib/index.js",
|
|
15
16
|
"types": "lib/index.d.ts",
|
|
16
17
|
"exports": {
|
|
17
18
|
".": {
|
|
18
19
|
"types": "./lib/index.d.ts",
|
|
20
|
+
"react-native": "./src/index.ts",
|
|
19
21
|
"import": "./lib/index.js",
|
|
20
|
-
"require": "./lib-commonjs/index.js",
|
|
21
22
|
"default": "./src/index.ts"
|
|
22
23
|
}
|
|
23
24
|
},
|
|
24
25
|
"scripts": {
|
|
25
|
-
"build": "
|
|
26
|
-
"build-cjs": "tsgo --outDir lib-commonjs",
|
|
27
|
-
"build-core": "tsgo --outDir lib --module esnext --moduleResolution bundler",
|
|
26
|
+
"build": "tsgo -b",
|
|
28
27
|
"clean": "fluentui-scripts clean",
|
|
29
28
|
"depcheck": "fluentui-scripts depcheck",
|
|
30
29
|
"format": "fluentui-scripts format",
|
|
31
30
|
"lint": "fluentui-scripts lint",
|
|
32
|
-
"lint-package": "fluentui-scripts lint-package",
|
|
33
31
|
"test": "fluentui-scripts jest",
|
|
34
32
|
"update-snapshots": "fluentui-scripts jest -u"
|
|
35
33
|
},
|
|
36
34
|
"dependencies": {
|
|
37
|
-
"@fluentui-react-native/adapters": "0.14.
|
|
38
|
-
"@fluentui-react-native/focus-zone": "0.22.
|
|
39
|
-
"@fluentui-react-native/framework": "0.
|
|
40
|
-
"@fluentui-react-native/
|
|
41
|
-
"@fluentui-react-native/
|
|
42
|
-
"@fluentui-react-native/
|
|
43
|
-
"@fluentui-react-native/
|
|
44
|
-
"@fluentui-react-native/tokens": "0.
|
|
45
|
-
"@fluentui-react-native/
|
|
46
|
-
"@
|
|
47
|
-
"@uifabricshared/foundation-
|
|
48
|
-
"@uifabricshared/foundation-
|
|
35
|
+
"@fluentui-react-native/adapters": "0.14.5",
|
|
36
|
+
"@fluentui-react-native/focus-zone": "0.22.5",
|
|
37
|
+
"@fluentui-react-native/framework": "0.16.1",
|
|
38
|
+
"@fluentui-react-native/framework-base": "0.4.1",
|
|
39
|
+
"@fluentui-react-native/interactive-hooks": "0.28.5",
|
|
40
|
+
"@fluentui-react-native/pressable": "0.13.5",
|
|
41
|
+
"@fluentui-react-native/text": "0.25.5",
|
|
42
|
+
"@fluentui-react-native/theme-tokens": "0.28.5",
|
|
43
|
+
"@fluentui-react-native/tokens": "0.24.5",
|
|
44
|
+
"@fluentui-react-native/use-styling": "0.15.1",
|
|
45
|
+
"@uifabricshared/foundation-composable": "0.14.5",
|
|
46
|
+
"@uifabricshared/foundation-compose": "1.16.5",
|
|
47
|
+
"@uifabricshared/foundation-settings": "0.16.5"
|
|
49
48
|
},
|
|
50
49
|
"devDependencies": {
|
|
51
50
|
"@babel/core": "^7.20.0",
|
|
52
|
-
"@fluentui-react-native/babel-config": "0.1.1",
|
|
53
|
-
"@fluentui-react-native/framework-base": "0.3.3",
|
|
54
|
-
"@fluentui-react-native/jest-config": "0.1.0",
|
|
55
|
-
"@fluentui-react-native/kit-config": "0.1.2",
|
|
56
|
-
"@fluentui-react-native/lint-config-rules": "0.1.3",
|
|
57
51
|
"@fluentui-react-native/scripts": "0.1.0",
|
|
58
52
|
"@fluentui-react-native/test-tools": "0.1.0",
|
|
59
|
-
"@office-iss/react-native-win32": "^0.
|
|
53
|
+
"@office-iss/react-native-win32": "^0.81.8",
|
|
60
54
|
"@react-native-community/cli": "^20.0.0",
|
|
61
55
|
"@react-native-community/cli-platform-android": "^20.0.0",
|
|
62
56
|
"@react-native-community/cli-platform-ios": "^20.0.0",
|
|
@@ -72,7 +66,7 @@
|
|
|
72
66
|
"react-test-renderer": "19.1.4"
|
|
73
67
|
},
|
|
74
68
|
"peerDependencies": {
|
|
75
|
-
"@office-iss/react-native-win32": "^0.74.0",
|
|
69
|
+
"@office-iss/react-native-win32": "^0.74.0 || ^0.81.0",
|
|
76
70
|
"@types/react": "~18.2.0 || ~19.0.0 || ~19.1.4",
|
|
77
71
|
"react": "18.2.0 || 19.0.0 || 19.1.4",
|
|
78
72
|
"react-native": "^0.73.0 || ^0.74.0 || ^0.78.0 || ^0.81.6",
|
|
@@ -94,6 +88,9 @@
|
|
|
94
88
|
"optional": true
|
|
95
89
|
}
|
|
96
90
|
},
|
|
91
|
+
"furn": {
|
|
92
|
+
"jestPlatform": "android"
|
|
93
|
+
},
|
|
97
94
|
"rnx-kit": {
|
|
98
95
|
"kitType": "library",
|
|
99
96
|
"alignDeps": {
|
|
@@ -106,11 +103,9 @@
|
|
|
106
103
|
"core-windows",
|
|
107
104
|
"react",
|
|
108
105
|
"react-test-renderer",
|
|
109
|
-
"svg"
|
|
110
|
-
"tools-core",
|
|
111
|
-
"tools-jest"
|
|
106
|
+
"svg"
|
|
112
107
|
]
|
|
113
108
|
},
|
|
114
|
-
"extends": "@fluentui-react-native/kit-config"
|
|
109
|
+
"extends": "@fluentui-react-native/scripts/kit-config"
|
|
115
110
|
}
|
|
116
111
|
}
|
|
@@ -11,12 +11,13 @@ import { useRadioGroupContext } from '../RadioGroup/radioGroupContext';
|
|
|
11
11
|
|
|
12
12
|
const defaultAccessibilityActions = [{ name: 'Select' }];
|
|
13
13
|
|
|
14
|
-
|
|
15
|
-
ArrowUp
|
|
16
|
-
ArrowDown
|
|
17
|
-
ArrowRight
|
|
18
|
-
ArrowLeft
|
|
19
|
-
}
|
|
14
|
+
const DirectionalArrowKeys = {
|
|
15
|
+
ArrowUp: 'ArrowUp',
|
|
16
|
+
ArrowDown: 'ArrowDown',
|
|
17
|
+
ArrowRight: 'ArrowRight',
|
|
18
|
+
ArrowLeft: 'ArrowLeft',
|
|
19
|
+
} as const;
|
|
20
|
+
type DirectionalArrowKeys = (typeof DirectionalArrowKeys)[keyof typeof DirectionalArrowKeys];
|
|
20
21
|
|
|
21
22
|
export const useRadio = (props: RadioProps): RadioInfo => {
|
|
22
23
|
const defaultComponentRef = React.useRef(null);
|
|
@@ -18,12 +18,13 @@ import type { IRadioButtonType, IRadioButtonProps, IRadioButtonSlotProps, IRadio
|
|
|
18
18
|
import { radioButtonName } from './RadioButton.types';
|
|
19
19
|
import { RadioGroupContext } from './RadioGroup';
|
|
20
20
|
|
|
21
|
-
|
|
22
|
-
ArrowUp
|
|
23
|
-
ArrowDown
|
|
24
|
-
ArrowRight
|
|
25
|
-
ArrowLeft
|
|
26
|
-
}
|
|
21
|
+
const DirectionalArrowKeys = {
|
|
22
|
+
ArrowUp: 'ArrowUp',
|
|
23
|
+
ArrowDown: 'ArrowDown',
|
|
24
|
+
ArrowRight: 'ArrowRight',
|
|
25
|
+
ArrowLeft: 'ArrowLeft',
|
|
26
|
+
} as const;
|
|
27
|
+
type DirectionalArrowKeys = (typeof DirectionalArrowKeys)[keyof typeof DirectionalArrowKeys];
|
|
27
28
|
|
|
28
29
|
export const RadioButton = compose<IRadioButtonType>({
|
|
29
30
|
displayName: radioButtonName,
|
package/tsconfig.json
CHANGED
|
@@ -1,7 +1,57 @@
|
|
|
1
1
|
{
|
|
2
|
-
"extends": "@fluentui-react-native/scripts/
|
|
2
|
+
"extends": "@fluentui-react-native/scripts/tsconfig",
|
|
3
3
|
"compilerOptions": {
|
|
4
|
-
"outDir": "lib"
|
|
4
|
+
"outDir": "lib",
|
|
5
|
+
"rootDir": "src",
|
|
6
|
+
"composite": true,
|
|
7
|
+
"tsBuildInfoFile": ".cache/tsconfig.tsbuildinfo"
|
|
5
8
|
},
|
|
6
|
-
"include": ["src"]
|
|
9
|
+
"include": ["src"],
|
|
10
|
+
"references": [
|
|
11
|
+
{
|
|
12
|
+
"path": "../../utils/adapters/tsconfig.json"
|
|
13
|
+
},
|
|
14
|
+
{
|
|
15
|
+
"path": "../FocusZone/tsconfig.json"
|
|
16
|
+
},
|
|
17
|
+
{
|
|
18
|
+
"path": "../../framework-base/tsconfig.json"
|
|
19
|
+
},
|
|
20
|
+
{
|
|
21
|
+
"path": "../../framework/framework/tsconfig.json"
|
|
22
|
+
},
|
|
23
|
+
{
|
|
24
|
+
"path": "../../utils/interactive-hooks/tsconfig.json"
|
|
25
|
+
},
|
|
26
|
+
{
|
|
27
|
+
"path": "../Pressable/tsconfig.json"
|
|
28
|
+
},
|
|
29
|
+
{
|
|
30
|
+
"path": "../../../scripts/tsconfig.json"
|
|
31
|
+
},
|
|
32
|
+
{
|
|
33
|
+
"path": "../../utils/test-tools/tsconfig.json"
|
|
34
|
+
},
|
|
35
|
+
{
|
|
36
|
+
"path": "../Text/tsconfig.json"
|
|
37
|
+
},
|
|
38
|
+
{
|
|
39
|
+
"path": "../../theming/theme-tokens/tsconfig.json"
|
|
40
|
+
},
|
|
41
|
+
{
|
|
42
|
+
"path": "../../utils/tokens/tsconfig.json"
|
|
43
|
+
},
|
|
44
|
+
{
|
|
45
|
+
"path": "../../framework/use-styling/tsconfig.json"
|
|
46
|
+
},
|
|
47
|
+
{
|
|
48
|
+
"path": "../../deprecated/foundation-composable/tsconfig.json"
|
|
49
|
+
},
|
|
50
|
+
{
|
|
51
|
+
"path": "../../deprecated/foundation-compose/tsconfig.json"
|
|
52
|
+
},
|
|
53
|
+
{
|
|
54
|
+
"path": "../../deprecated/foundation-settings/tsconfig.json"
|
|
55
|
+
}
|
|
56
|
+
]
|
|
7
57
|
}
|
package/babel.config.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
module.exports = require('@fluentui-react-native/babel-config');
|
package/jest.config.js
DELETED
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
import type { PressableState } from '@fluentui-react-native/interactive-hooks';
|
|
2
|
-
import type { RadioProps } from './Radio.types';
|
|
3
|
-
/**
|
|
4
|
-
* A function which determines if a set of styles should be applied to the component given the current state and props of the Radio.
|
|
5
|
-
*
|
|
6
|
-
* @param layer The name of the state that is being checked for
|
|
7
|
-
* @param state The current state of the Radio
|
|
8
|
-
* @param userProps The props that were passed into the Radio
|
|
9
|
-
* @returns Whether the styles that are assigned to the layer should be applied to the Radio
|
|
10
|
-
*/
|
|
11
|
-
export declare const radioLookup: (layer: string, state: PressableState, userProps: RadioProps) => boolean;
|
|
12
|
-
export declare const Radio: import("@fluentui-react-native/framework").ComposableComponent<RadioProps, import("./Radio.types").RadioSlotProps, import("./Radio.types").RadioTokens, import("@fluentui-react-native/framework").ObjectBase>;
|
|
13
|
-
//# sourceMappingURL=Radio.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"Radio.d.ts","sourceRoot":"","sources":["../../src/Radio/Radio.tsx"],"names":[],"mappings":"AAKA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,0CAA0C,CAAC;AAI/E,OAAO,KAAK,EAAa,UAAU,EAAE,MAAM,eAAe,CAAC;AAI3D;;;;;;;GAOG;AACH,eAAO,MAAM,WAAW,0EAQvB,CAAC;AAEF,eAAO,MAAM,KAAK,gNA6ChB,CAAC"}
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
import type { PressableState } from '@fluentui-react-native/interactive-hooks';
|
|
2
|
-
import type { RadioProps } from './Radio.types';
|
|
3
|
-
/**
|
|
4
|
-
* A function which determines if a set of styles should be applied to the component given the current state and props of the Radio.
|
|
5
|
-
*
|
|
6
|
-
* @param layer The name of the state that is being checked for
|
|
7
|
-
* @param state The current state of the Radio
|
|
8
|
-
* @param userProps The props that were passed into the Radio
|
|
9
|
-
* @returns Whether the styles that are assigned to the layer should be applied to the Radio
|
|
10
|
-
*/
|
|
11
|
-
export declare const radioLookup: (layer: string, state: PressableState, userProps: RadioProps) => boolean;
|
|
12
|
-
export declare const Radio: import("@fluentui-react-native/framework").ComposableComponent<RadioProps, import("./Radio.types").RadioSlotProps, import("./Radio.types").RadioTokens, import("@fluentui-react-native/framework").ObjectBase>;
|
|
13
|
-
//# sourceMappingURL=Radio.ios.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"Radio.ios.d.ts","sourceRoot":"","sources":["../../src/Radio/Radio.ios.tsx"],"names":[],"mappings":"AAKA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,0CAA0C,CAAC;AAK/E,OAAO,KAAK,EAAa,UAAU,EAAE,MAAM,eAAe,CAAC;AAI3D;;;;;;;GAOG;AACH,eAAO,MAAM,WAAW,0EAQvB,CAAC;AAEF,eAAO,MAAM,KAAK,gNAqDhB,CAAC"}
|
|
@@ -1,55 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.Radio = exports.radioLookup = void 0;
|
|
4
|
-
const jsx_runtime_1 = require("@fluentui-react-native/framework-base/jsx-runtime");
|
|
5
|
-
/** @jsxImportSource @fluentui-react-native/framework-base */
|
|
6
|
-
const react_native_1 = require("react-native");
|
|
7
|
-
const framework_1 = require("@fluentui-react-native/framework");
|
|
8
|
-
const text_1 = require("@fluentui-react-native/text");
|
|
9
|
-
const react_native_svg_1 = require("react-native-svg");
|
|
10
|
-
const Radio_styling_1 = require("./Radio.styling");
|
|
11
|
-
const Radio_types_1 = require("./Radio.types");
|
|
12
|
-
const useRadio_1 = require("./useRadio");
|
|
13
|
-
/**
|
|
14
|
-
* A function which determines if a set of styles should be applied to the component given the current state and props of the Radio.
|
|
15
|
-
*
|
|
16
|
-
* @param layer The name of the state that is being checked for
|
|
17
|
-
* @param state The current state of the Radio
|
|
18
|
-
* @param userProps The props that were passed into the Radio
|
|
19
|
-
* @returns Whether the styles that are assigned to the layer should be applied to the Radio
|
|
20
|
-
*/
|
|
21
|
-
const radioLookup = (layer, state, userProps) => {
|
|
22
|
-
return (state[layer] ||
|
|
23
|
-
userProps[layer] ||
|
|
24
|
-
(!(react_native_1.Platform.OS === 'win32' || react_native_1.Platform.OS === 'android') &&
|
|
25
|
-
layer === 'labelPositionBelow' &&
|
|
26
|
-
userProps['labelPosition'] === 'below'));
|
|
27
|
-
};
|
|
28
|
-
exports.radioLookup = radioLookup;
|
|
29
|
-
exports.Radio = (0, framework_1.compose)({
|
|
30
|
-
displayName: Radio_types_1.radioName,
|
|
31
|
-
...Radio_styling_1.stylingSettings,
|
|
32
|
-
slots: {
|
|
33
|
-
root: react_native_1.Pressable,
|
|
34
|
-
button: react_native_1.Pressable,
|
|
35
|
-
checkmark: react_native_svg_1.Svg,
|
|
36
|
-
labelContent: react_native_1.View,
|
|
37
|
-
label: text_1.TextV1,
|
|
38
|
-
subtext: text_1.TextV1,
|
|
39
|
-
},
|
|
40
|
-
useRender: (userProps, useSlots) => {
|
|
41
|
-
const radio = (0, useRadio_1.useRadio)(userProps);
|
|
42
|
-
const Slots = useSlots(userProps, (layer) => (0, exports.radioLookup)(layer, radio.state, radio.props));
|
|
43
|
-
// now return the handler for finishing render
|
|
44
|
-
return (final) => {
|
|
45
|
-
const { label, subtext, ...mergedProps } = (0, framework_1.mergeProps)(radio.props, final);
|
|
46
|
-
const { onPress, disabled, onPressIn, onPressOut } = mergedProps;
|
|
47
|
-
const labelComponent = (jsx_runtime_1.jsxs(Slots.labelContent, { children: [
|
|
48
|
-
jsx_runtime_1.jsx(Slots.label, { children: label }), !!subtext && jsx_runtime_1.jsx(Slots.subtext, { children: subtext })] }));
|
|
49
|
-
const checkmarkPath = (jsx_runtime_1.jsx(react_native_svg_1.Path, { fill: "currentColor", d: "M9.76497 3.20474C10.0661 3.48915 10.0797 3.96383 9.79526 4.26497L5.54526 8.76497C5.40613 8.91228 5.21332 8.99703 5.01071 8.99993C4.8081 9.00282 4.61295 8.92361 4.46967 8.78033L2.21967 6.53033C1.92678 6.23744 1.92678 5.76257 2.21967 5.46967C2.51256 5.17678 2.98744 5.17678 3.28033 5.46967L4.98463 7.17397L8.70474 3.23503C8.98915 2.9339 9.46383 2.92033 9.76497 3.20474Z" }));
|
|
50
|
-
return (jsx_runtime_1.jsxs(Slots.root, { ...mergedProps, accessible: !disabled, focusable: !disabled, children: [
|
|
51
|
-
jsx_runtime_1.jsx(Slots.button, { accessible: false, onPress: onPress, onPressIn: onPressIn, onPressOut: onPressOut, disabled: disabled, focusable: false, children: jsx_runtime_1.jsx(Slots.checkmark, { viewBox: "0 0 12 12", children: checkmarkPath }, "checkmark") }), labelComponent] }));
|
|
52
|
-
};
|
|
53
|
-
},
|
|
54
|
-
});
|
|
55
|
-
//# sourceMappingURL=Radio.ios.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"Radio.ios.js","sourceRoot":"","sources":["../../src/Radio/Radio.ios.tsx"],"names":[],"mappings":";;;;AAAA,6DAA6D;AAC7D,+CAAyD;AAGzD,gEAAuE;AAEvE,sDAA6D;AAC7D,uDAA6C;AAE7C,mDAAkD;AAElD,+CAA0C;AAC1C,yCAAsC;AAEtC;;;;;;;GAOG;AACI,MAAM,WAAW,GAAG,CAAC,KAAa,EAAE,KAAqB,EAAE,SAAqB,EAAW,EAAE,CAAC;IACnG,OAAO,CACL,KAAK,CAAC,KAAK,CAAC;QACZ,SAAS,CAAC,KAAK,CAAC;QAChB,CAAC,CAAC,CAAC,uBAAQ,CAAC,EAAE,KAAM,OAAe,IAAI,uBAAQ,CAAC,EAAE,KAAK,SAAS,CAAC;YAC/D,KAAK,KAAK,oBAAoB;YAC9B,SAAS,CAAC,eAAe,CAAC,KAAK,OAAO,CAAC,CAC1C,CAAC;AAAA,CACH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WAAW,EAAQ,UAAU,EAAE,CAAC,QAAQ,EAAE,SAAS,EAAE,CAAC,QAAQ;oBAC5E,kBAAC,KAAK,CAAC,MAAM,IACX,UAAU,EAAE,KAAK,EACjB,OAAO,EAAE,OAAO,EAChB,SAAS,EAAE,SAAS,EACpB,UAAU,EAAE,UAAU,EACtB,QAAQ,EAAE,QAAQ,EAClB,SAAS,EAAE,KAAK,YAEhB,kBAAC,KAAK,CAAC,SAAS,IAAiB,OAAO,EAAC,WAAW,YACjD,aAAa,IADK,WAAW,CAEd,GACL,EACd,cAAc,IACJ,CACd,CAAC;QAAA,CACH,CAAC;IAAA,CACH;CACF,CAAC,CAAC"}
|
|
@@ -1,54 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.Radio = exports.radioLookup = void 0;
|
|
4
|
-
const jsx_runtime_1 = require("@fluentui-react-native/framework-base/jsx-runtime");
|
|
5
|
-
/** @jsxImportSource @fluentui-react-native/framework-base */
|
|
6
|
-
const react_native_1 = require("react-native");
|
|
7
|
-
const framework_1 = require("@fluentui-react-native/framework");
|
|
8
|
-
const text_1 = require("@fluentui-react-native/text");
|
|
9
|
-
const Radio_styling_1 = require("./Radio.styling");
|
|
10
|
-
const Radio_types_1 = require("./Radio.types");
|
|
11
|
-
const useRadio_1 = require("./useRadio");
|
|
12
|
-
/**
|
|
13
|
-
* A function which determines if a set of styles should be applied to the component given the current state and props of the Radio.
|
|
14
|
-
*
|
|
15
|
-
* @param layer The name of the state that is being checked for
|
|
16
|
-
* @param state The current state of the Radio
|
|
17
|
-
* @param userProps The props that were passed into the Radio
|
|
18
|
-
* @returns Whether the styles that are assigned to the layer should be applied to the Radio
|
|
19
|
-
*/
|
|
20
|
-
const radioLookup = (layer, state, userProps) => {
|
|
21
|
-
return (state[layer] ||
|
|
22
|
-
userProps[layer] ||
|
|
23
|
-
(!(react_native_1.Platform.OS === 'win32' || react_native_1.Platform.OS === 'android') &&
|
|
24
|
-
layer === 'labelPositionBelow' &&
|
|
25
|
-
userProps['labelPosition'] === 'below'));
|
|
26
|
-
};
|
|
27
|
-
exports.radioLookup = radioLookup;
|
|
28
|
-
exports.Radio = (0, framework_1.compose)({
|
|
29
|
-
displayName: Radio_types_1.radioName,
|
|
30
|
-
...Radio_styling_1.stylingSettings,
|
|
31
|
-
slots: {
|
|
32
|
-
root: react_native_1.Pressable,
|
|
33
|
-
button: react_native_1.Pressable,
|
|
34
|
-
innerCircle: react_native_1.View,
|
|
35
|
-
labelContent: react_native_1.View,
|
|
36
|
-
label: text_1.TextV1,
|
|
37
|
-
subtext: text_1.TextV1,
|
|
38
|
-
},
|
|
39
|
-
useRender: (userProps, useSlots) => {
|
|
40
|
-
const radio = (0, useRadio_1.useRadio)(userProps);
|
|
41
|
-
const Slots = useSlots(userProps, (layer) => (0, exports.radioLookup)(layer, radio.state, radio.props));
|
|
42
|
-
// now return the handler for finishing render
|
|
43
|
-
return (final) => {
|
|
44
|
-
const { label, subtext, ...mergedProps } = (0, framework_1.mergeProps)(radio.props, final);
|
|
45
|
-
const { onPress, disabled, onPressIn, onPressOut } = mergedProps;
|
|
46
|
-
const isMobile = react_native_1.Platform.OS === 'android' || react_native_1.Platform.OS === 'ios';
|
|
47
|
-
const labelComponent = (jsx_runtime_1.jsxs(Slots.labelContent, { children: [
|
|
48
|
-
jsx_runtime_1.jsx(Slots.label, { children: label }), !!subtext && jsx_runtime_1.jsx(Slots.subtext, { children: subtext })] }));
|
|
49
|
-
return (jsx_runtime_1.jsxs(Slots.root, { ...mergedProps, ...(isMobile && { accessible: !disabled, focusable: !disabled }), children: [
|
|
50
|
-
jsx_runtime_1.jsx(Slots.button, { accessible: false, onPress: onPress, onPressIn: onPressIn, onPressOut: onPressOut, disabled: disabled, focusable: false, children: jsx_runtime_1.jsx(Slots.innerCircle, {}) }), labelComponent] }));
|
|
51
|
-
};
|
|
52
|
-
},
|
|
53
|
-
});
|
|
54
|
-
//# source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CAAC,KAAiB,EAAE,EAAE,CAAC;YAC5B,MAAM,EAAE,KAAK,EAAE,OAAO,EAAE,GAAG,WAAW,EAAE,GAAG,IAAA,sBAAU,EAAC,KAAK,CAAC,KAAK,EAAE,KAAK,CAAC,CAAC;YAC1E,MAAM,EAAE,OAAO,EAAE,QAAQ,EAAE,SAAS,EAAE,UAAU,EAAE,GAAG,WAAW,CAAC;YACjE,MAAM,QAAQ,GAAG,uBAAQ,CAAC,EAAE,KAAK,SAAS,IAAI,uBAAQ,CAAC,EAAE,KAAK,KAAK,CAAC;YAEpE,MAAM,cAAc,GAAG,CACrB,mBAAC,KAAK,CAAC,YAAY;oBACjB,kBAAC,KAAK,CAAC,KAAK,cAAE,KAAK,GAAe,EACjC,CAAC,CAAC,OAAO,IAAI,kBAAC,KAAK,CAAC,OAAO,cAAE,OAAO,GAAiB,IACnC,CACtB,CAAC;YAEF,OAAO,CACL,mBAAC,KAAK,CAAC,IAAI,OAAK,WAAW,KAAM,CAAC,QAAQ,IAAI,EAAE,UAAU,EAAE,CAAC,QAAQ,EAAE,SAAS,EAAE,CAAC,QAAQ,EAAE,CAAC;oBAC5F,kBAAC,KAAK,CAAC,MAAM,IACX,UAAU,EAAE,KAAK,EACjB,OAAO,EAAE,OAAO,EAChB,SAAS,EAAE,SAAS,EACpB,UAAU,EAAE,UAAU,EACtB,QAAQ,EAAE,QAAQ,EAClB,SAAS,EAAE,KAAK,YAEhB,kBAAC,KAAK,CAAC,WAAW,KAAG,GACR,EACd,cAAc,IACJ,CACd,CAAC;QAAA,CACH,CAAC;IAAA,CACH;CACF,CAAC,CAAC"}
|
|
@@ -1,5 +0,0 @@
|
|
|
1
|
-
import type { UseStylingOptions } from '@fluentui-react-native/framework';
|
|
2
|
-
import type { RadioTokens, RadioSlotProps, RadioProps } from './Radio.types';
|
|
3
|
-
export declare const radioStates: (keyof RadioTokens)[];
|
|
4
|
-
export declare const stylingSettings: UseStylingOptions<RadioProps, RadioSlotProps, RadioTokens>;
|
|
5
|
-
//# sourceMappingURL=Radio.styling.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"Radio.styling.d.ts","sourceRoot":"","sources":["../../src/Radio/Radio.styling.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAS,iBAAiB,EAAE,MAAM,kCAAkC,CAAC;AAIjF,OAAO,KAAK,EAAE,WAAW,EAAE,cAAc,EAAE,UAAU,EAAE,MAAM,eAAe,CAAC;AAI7E,eAAO,MAAM,WAAW,EAAE,CAAC,MAAM,WAAW,CAAC,EAAoF,CAAC;AAElI,eAAO,MAAM,eAAe,EAAE,iBAAiB,CAAC,UAAU,EAAE,cAAc,EAAE,WAAW,CA6GtF,CAAC"}
|
|
@@ -1,98 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.stylingSettings = exports.radioStates = void 0;
|
|
4
|
-
const framework_1 = require("@fluentui-react-native/framework");
|
|
5
|
-
const tokens_1 = require("@fluentui-react-native/tokens");
|
|
6
|
-
const Radio_types_1 = require("./Radio.types");
|
|
7
|
-
const RadioTokens_1 = require("./RadioTokens");
|
|
8
|
-
exports.radioStates = ['labelPositionBelow', 'focused', 'hovered', 'pressed', 'selected', 'disabled'];
|
|
9
|
-
exports.stylingSettings = {
|
|
10
|
-
tokens: [RadioTokens_1.defaultRadioTokens, Radio_types_1.radioName],
|
|
11
|
-
states: exports.radioStates,
|
|
12
|
-
slotProps: {
|
|
13
|
-
root: (0, framework_1.buildProps)((tokens) => ({
|
|
14
|
-
style: {
|
|
15
|
-
display: 'flex',
|
|
16
|
-
alignItems: tokens.alignItems,
|
|
17
|
-
flexDirection: tokens.flexDirection,
|
|
18
|
-
paddingHorizontal: tokens.rootHorizontalPadding,
|
|
19
|
-
paddingVertical: tokens.rootVerticalPadding,
|
|
20
|
-
},
|
|
21
|
-
android_ripple: { color: tokens.rippleColor },
|
|
22
|
-
}), ['flexDirection', 'rootHorizontalPadding', 'rootVerticalPadding', 'rippleColor', 'alignItems']),
|
|
23
|
-
button: (0, framework_1.buildProps)((tokens) => ({
|
|
24
|
-
style: {
|
|
25
|
-
backgroundColor: tokens.radioOuterCircleBackground,
|
|
26
|
-
width: tokens.radioOuterCircleSize,
|
|
27
|
-
height: tokens.radioOuterCircleSize,
|
|
28
|
-
alignItems: 'center',
|
|
29
|
-
justifyContent: 'center',
|
|
30
|
-
borderWidth: tokens.radioBorderWidth,
|
|
31
|
-
borderStyle: tokens.radioBorderStyle,
|
|
32
|
-
borderRadius: tokens.radioOuterCircleSize / 2,
|
|
33
|
-
borderColor: tokens.radioBorder,
|
|
34
|
-
marginTop: tokens.marginTop,
|
|
35
|
-
marginRight: tokens.marginRight,
|
|
36
|
-
marginBottom: tokens.marginBottom,
|
|
37
|
-
marginLeft: tokens.marginLeft,
|
|
38
|
-
},
|
|
39
|
-
android_ripple: { color: tokens.rippleColor, radius: tokens.rippleRadius, borderless: true },
|
|
40
|
-
}), [
|
|
41
|
-
'radioOuterCircleBackground',
|
|
42
|
-
'radioBorderWidth',
|
|
43
|
-
'radioBorderStyle',
|
|
44
|
-
'radioOuterCircleSize',
|
|
45
|
-
'rippleColor',
|
|
46
|
-
'rippleRadius',
|
|
47
|
-
'radioBorder',
|
|
48
|
-
'marginTop',
|
|
49
|
-
'marginRight',
|
|
50
|
-
'marginBottom',
|
|
51
|
-
'marginLeft',
|
|
52
|
-
]),
|
|
53
|
-
innerCircle: (0, framework_1.buildProps)((tokens) => ({
|
|
54
|
-
style: {
|
|
55
|
-
opacity: tokens.radioVisibility,
|
|
56
|
-
borderRadius: tokens.radioInnerCircleSize / 2,
|
|
57
|
-
height: tokens.radioInnerCircleSize,
|
|
58
|
-
width: tokens.radioInnerCircleSize,
|
|
59
|
-
backgroundColor: tokens.radioFill,
|
|
60
|
-
},
|
|
61
|
-
}), ['radioInnerCircleSize', 'radioVisibility', 'radioFill']),
|
|
62
|
-
labelContent: (0, framework_1.buildProps)((tokens, theme) => ({
|
|
63
|
-
style: {
|
|
64
|
-
alignItems: tokens.labelAlignItems,
|
|
65
|
-
flexDirection: 'column',
|
|
66
|
-
marginRight: tokens.labelMarginRight,
|
|
67
|
-
marginLeft: tokens.labelMarginLeft,
|
|
68
|
-
padding: tokens.labelPadding,
|
|
69
|
-
paddingRight: 0,
|
|
70
|
-
...tokens_1.borderStyles.from(tokens, theme),
|
|
71
|
-
},
|
|
72
|
-
}), ['labelAlignItems', 'labelMarginRight', 'labelMarginLeft', 'labelPadding', ...tokens_1.borderStyles.keys]),
|
|
73
|
-
checkmark: (0, framework_1.buildProps)((tokens) => ({
|
|
74
|
-
style: {
|
|
75
|
-
opacity: tokens.radioVisibility,
|
|
76
|
-
},
|
|
77
|
-
}), ['radioVisibility']),
|
|
78
|
-
label: (0, framework_1.buildProps)((tokens, theme) => ({
|
|
79
|
-
variant: tokens.variant,
|
|
80
|
-
style: {
|
|
81
|
-
marginVertical: tokens.labelMarginVertical,
|
|
82
|
-
marginHorizontal: 2,
|
|
83
|
-
color: tokens.color,
|
|
84
|
-
...tokens_1.fontStyles.from(tokens, theme),
|
|
85
|
-
},
|
|
86
|
-
}), ['variant', 'labelMarginVertical', 'color', ...tokens_1.fontStyles.keys]),
|
|
87
|
-
subtext: (0, framework_1.buildProps)((tokens) => ({
|
|
88
|
-
variant: tokens.subtextVariant,
|
|
89
|
-
style: {
|
|
90
|
-
marginTop: tokens.subtextMarginTop,
|
|
91
|
-
marginBottom: tokens.subtextMarginBottom,
|
|
92
|
-
marginHorizontal: 2,
|
|
93
|
-
color: tokens.color,
|
|
94
|
-
},
|
|
95
|
-
}), ['subtextMarginTop', 'subtextMarginBottom', 'color', 'subtextVariant']),
|
|
96
|
-
},
|
|
97
|
-
};
|
|
98
|
-
//# sourceMappingURL=Radio.styling.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"Radio.styling.js","sourceRoot":"","sources":["../../src/Radio/Radio.styling.ts"],"names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