@bitrise/bitkit 9.5.2 → 9.5.3-alpha-src.1
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/package.json +4 -1
- package/src/tsconfig.tsbuildinfo +1 -0
- package/.browserslistrc +0 -2
- package/.editorconfig +0 -4
- package/.eslint-tsconfig.json +0 -7
- package/.eslintrc.js +0 -28
- package/.husky/commit-msg +0 -4
- package/.nvmrc +0 -1
- package/.storybook/main.js +0 -35
- package/.storybook/manager.js +0 -6
- package/.storybook/preview.tsx +0 -20
- package/.storybook/theme.js +0 -7
- package/.stylelintignore +0 -2
- package/.stylelintrc +0 -287
- package/.svgrrc.js +0 -52
- package/.tool-versions +0 -1
- package/@types/@bitrise/bitkit.ts +0 -1
- package/@types/react-docgen.ts +0 -119
- package/CHANGELOG.md +0 -996
- package/CONTRIBUTING.md +0 -79
- package/FAQ.md +0 -19
- package/bitrise.yml +0 -66
- package/commitlint.config.js +0 -10
- package/jest.setup.js +0 -36
- package/netlify.toml +0 -42
- package/postcss.config.js +0 -16
- package/release.config.js +0 -32
- package/renovate.json +0 -6
- package/scripts/build-docs-watch.ts +0 -7
- package/scripts/build-docs.ts +0 -59
- package/site/assets/fonts/TT_Norms_Pro_Bold.woff +0 -0
- package/site/assets/fonts/TT_Norms_Pro_Normal.woff +0 -0
- package/site/assets/icons/favicon-32x32.png +0 -0
- package/site/assets/images/app_icon.jpg +0 -0
- package/site/assets/images/status-checks.png +0 -0
- package/site/components/CodeBlock/CodeBlock.css +0 -87
- package/site/components/CodeBlock/CodeBlock.tsx +0 -35
- package/site/components/Documentation/ComponentDocumentationPage.tsx +0 -150
- package/site/components/Documentation/Components/SectionAddonBeam.tsx +0 -47
- package/site/components/Documentation/Components/SectionAddonBeamSandbox.tsx +0 -32
- package/site/components/Documentation/Components/SectionAddonFooter.tsx +0 -22
- package/site/components/Documentation/Components/SectionAppear.tsx +0 -59
- package/site/components/Documentation/Components/SectionAvatar.tsx +0 -50
- package/site/components/Documentation/Components/SectionBadge.tsx +0 -38
- package/site/components/Documentation/Components/SectionBase.tsx +0 -17
- package/site/components/Documentation/Components/SectionButtons.tsx +0 -361
- package/site/components/Documentation/Components/SectionCards.tsx +0 -276
- package/site/components/Documentation/Components/SectionCheckbox.tsx +0 -38
- package/site/components/Documentation/Components/SectionDatePicker.tsx +0 -82
- package/site/components/Documentation/Components/SectionDivider.tsx +0 -31
- package/site/components/Documentation/Components/SectionDot.tsx +0 -27
- package/site/components/Documentation/Components/SectionDropdowns.tsx +0 -388
- package/site/components/Documentation/Components/SectionExpand.tsx +0 -143
- package/site/components/Documentation/Components/SectionFlex.tsx +0 -33
- package/site/components/Documentation/Components/SectionFormElements.tsx +0 -187
- package/site/components/Documentation/Components/SectionGrid.tsx +0 -125
- package/site/components/Documentation/Components/SectionHamburger.tsx +0 -34
- package/site/components/Documentation/Components/SectionIcons.tsx +0 -30
- package/site/components/Documentation/Components/SectionInputs.tsx +0 -89
- package/site/components/Documentation/Components/SectionList.tsx +0 -26
- package/site/components/Documentation/Components/SectionModals.tsx +0 -224
- package/site/components/Documentation/Components/SectionNotification.tsx +0 -38
- package/site/components/Documentation/Components/SectionPlacement.tsx +0 -167
- package/site/components/Documentation/Components/SectionProgress.tsx +0 -149
- package/site/components/Documentation/Components/SectionRadioButton.tsx +0 -38
- package/site/components/Documentation/Components/SectionRibbon.tsx +0 -33
- package/site/components/Documentation/Components/SectionRibbonSandbox.tsx +0 -17
- package/site/components/Documentation/Components/SectionSidebar.tsx +0 -125
- package/site/components/Documentation/Components/SectionSkeleton.tsx +0 -99
- package/site/components/Documentation/Components/SectionStatus.tsx +0 -53
- package/site/components/Documentation/Components/SectionStatusSandbox404.tsx +0 -42
- package/site/components/Documentation/Components/SectionStatusSandbox500.tsx +0 -13
- package/site/components/Documentation/Components/SectionTable.tsx +0 -83
- package/site/components/Documentation/Components/SectionTabs.tsx +0 -25
- package/site/components/Documentation/Components/SectionText.tsx +0 -34
- package/site/components/Documentation/Components/SectionTextarea.tsx +0 -43
- package/site/components/Documentation/Components/SectionToggle.tsx +0 -50
- package/site/components/Documentation/Components/SectionTooltips.tsx +0 -50
- package/site/components/Documentation/Documentation.tsx +0 -302
- package/site/components/Documentation/Materials/SectionColors.css +0 -33
- package/site/components/Documentation/Materials/SectionColors.tsx +0 -197
- package/site/components/Documentation/Materials/SectionIcons.tsx +0 -106
- package/site/components/Documentation/Materials/SectionTypography.tsx +0 -143
- package/site/components/Page/Page.tsx +0 -8
- package/site/components/Page/PageTitle.tsx +0 -8
- package/site/components/PropsTable/PropsTable.tsx +0 -35
- package/site/components/PropsTable/PropsTableCellUnion.tsx +0 -29
- package/site/components/PropsTable/PropsTableRow.tsx +0 -55
- package/site/components/Root/Root.tsx +0 -89
- package/site/components/Root/index.tsx +0 -4
- package/site/components/Sandbox/Sandbox.tsx +0 -19
- package/site/components/Sandbox/SandboxFrame.css +0 -20
- package/site/components/Sandbox/SandboxFrame.tsx +0 -77
- package/site/components/Section/Section.tsx +0 -8
- package/site/components/Section/SectionSubTitle.tsx +0 -8
- package/site/components/Section/SectionTitle.tsx +0 -8
- package/site/components/SideMenu/SideMenu.css +0 -39
- package/site/components/SideMenu/SideMenu.tsx +0 -53
- package/site/components/SideMenu/SideMenuItem.tsx +0 -34
- package/site/components/Window/Window.tsx +0 -62
- package/site/index.css +0 -11
- package/site/index.html +0 -16
- package/site/index.tsx +0 -16
- package/superstatic.json +0 -13
- package/tsconfig.json +0 -25
|
@@ -1,125 +0,0 @@
|
|
|
1
|
-
import * as React from 'react';
|
|
2
|
-
import {
|
|
3
|
-
Badge,
|
|
4
|
-
Flex,
|
|
5
|
-
Sidebar,
|
|
6
|
-
SidebarMenu,
|
|
7
|
-
SidebarMenuItem,
|
|
8
|
-
SidebarSubMenu,
|
|
9
|
-
SidebarSubMenuItem,
|
|
10
|
-
Text,
|
|
11
|
-
} from '@bitrise/bitkit';
|
|
12
|
-
import CodeBlock from '../../CodeBlock/CodeBlock';
|
|
13
|
-
import Section from '../../Section/Section';
|
|
14
|
-
|
|
15
|
-
const { useState } = React;
|
|
16
|
-
|
|
17
|
-
const SectionSidebar = () => {
|
|
18
|
-
const [active, setActive] = useState('1');
|
|
19
|
-
|
|
20
|
-
return (
|
|
21
|
-
<Section>
|
|
22
|
-
<Flex direction="horizontal" gap="x6">
|
|
23
|
-
{(['dark', 'light'] as ('dark' | 'light')[]).map((theme) => (
|
|
24
|
-
<Flex container direction="vertical" grow height="30rem" initial="none" key={theme}>
|
|
25
|
-
<Text margin="x3" size="2">
|
|
26
|
-
{theme}
|
|
27
|
-
</Text>
|
|
28
|
-
<Sidebar theme={theme}>
|
|
29
|
-
<SidebarMenu active={active === '1'}>
|
|
30
|
-
<SidebarMenuItem icon="BuildstatusLoading" onClick={() => setActive('1')}>
|
|
31
|
-
MenuItem
|
|
32
|
-
</SidebarMenuItem>
|
|
33
|
-
</SidebarMenu>
|
|
34
|
-
|
|
35
|
-
<SidebarMenu active={active.startsWith('2')}>
|
|
36
|
-
<SidebarMenuItem icon="BuildstatusLoading" onClick={() => setActive('2')}>
|
|
37
|
-
MenuItem
|
|
38
|
-
</SidebarMenuItem>
|
|
39
|
-
|
|
40
|
-
<SidebarSubMenu>
|
|
41
|
-
<SidebarSubMenuItem active={active === '2/1'} onClick={() => setActive('2/1')}>
|
|
42
|
-
SubMenuItem
|
|
43
|
-
</SidebarSubMenuItem>
|
|
44
|
-
|
|
45
|
-
<SidebarSubMenuItem active={active === '2/2'} onClick={() => setActive('2/2')}>
|
|
46
|
-
SubMenuItem
|
|
47
|
-
</SidebarSubMenuItem>
|
|
48
|
-
|
|
49
|
-
<SidebarSubMenuItem active={active === '2/3'} onClick={() => setActive('2/3')}>
|
|
50
|
-
SubMenuItem
|
|
51
|
-
</SidebarSubMenuItem>
|
|
52
|
-
</SidebarSubMenu>
|
|
53
|
-
</SidebarMenu>
|
|
54
|
-
|
|
55
|
-
<SidebarMenu active={active.startsWith('3')}>
|
|
56
|
-
<SidebarMenuItem icon="BuildstatusLoading" onClick={() => setActive('3')}>
|
|
57
|
-
<Flex direction="horizontal" gap="x2">
|
|
58
|
-
<Flex>MenuItem</Flex>
|
|
59
|
-
<Flex>
|
|
60
|
-
<Badge backgroundColor="blue-3" textColor="gray-1">
|
|
61
|
-
BETA
|
|
62
|
-
</Badge>
|
|
63
|
-
</Flex>
|
|
64
|
-
</Flex>
|
|
65
|
-
</SidebarMenuItem>
|
|
66
|
-
|
|
67
|
-
<SidebarSubMenu>
|
|
68
|
-
<SidebarSubMenuItem active={active === '3/1'} onClick={() => setActive('3/1')}>
|
|
69
|
-
SubMenuItem
|
|
70
|
-
</SidebarSubMenuItem>
|
|
71
|
-
|
|
72
|
-
<SidebarSubMenuItem active={active === '3/2'} onClick={() => setActive('3/2')}>
|
|
73
|
-
SubMenuItem
|
|
74
|
-
</SidebarSubMenuItem>
|
|
75
|
-
|
|
76
|
-
<SidebarSubMenuItem active={active === '3/3'} onClick={() => setActive('3/3')}>
|
|
77
|
-
SubMenuItem
|
|
78
|
-
</SidebarSubMenuItem>
|
|
79
|
-
</SidebarSubMenu>
|
|
80
|
-
</SidebarMenu>
|
|
81
|
-
</Sidebar>
|
|
82
|
-
</Flex>
|
|
83
|
-
))}
|
|
84
|
-
</Flex>
|
|
85
|
-
|
|
86
|
-
<CodeBlock title="Sidebar Usage Example">{`const Component = () => {
|
|
87
|
-
const [active, setActive] = useState();
|
|
88
|
-
|
|
89
|
-
return (
|
|
90
|
-
<Sidebar>
|
|
91
|
-
<SidebarMenu active={ active.startsWith('/1') }>
|
|
92
|
-
<SidebarMenuItem onClick={ () => setActive('/1') }>
|
|
93
|
-
1
|
|
94
|
-
</SidebarMenuItem>
|
|
95
|
-
</SidebarMenu>
|
|
96
|
-
|
|
97
|
-
<SidebarMenu active={ active.startsWith('/2') }>
|
|
98
|
-
<SidebarMenuItem onClick={ () => setActive('/2/1') }>
|
|
99
|
-
2
|
|
100
|
-
</SidebarMenuItem>
|
|
101
|
-
|
|
102
|
-
<SidebarSubMenu>
|
|
103
|
-
<SidebarSubMenuItem
|
|
104
|
-
active={ active === '/2/1' }
|
|
105
|
-
icon="App"
|
|
106
|
-
onClick={ () => setActive('/2/1') }>
|
|
107
|
-
2 / 1
|
|
108
|
-
</SidebarSubMenuItem>
|
|
109
|
-
|
|
110
|
-
<SidebarSubMenuItem
|
|
111
|
-
active={ active === '/2/2' }
|
|
112
|
-
icon="Trigger"
|
|
113
|
-
onClick={ () => setActive('/2/2') }>
|
|
114
|
-
2 / 2
|
|
115
|
-
</SidebarSubMenuItem>
|
|
116
|
-
</SidebarSubMenu>
|
|
117
|
-
</SidebarMenu>
|
|
118
|
-
</Sidebar>
|
|
119
|
-
);
|
|
120
|
-
};`}</CodeBlock>
|
|
121
|
-
</Section>
|
|
122
|
-
);
|
|
123
|
-
};
|
|
124
|
-
|
|
125
|
-
export default SectionSidebar;
|
|
@@ -1,99 +0,0 @@
|
|
|
1
|
-
import * as React from 'react';
|
|
2
|
-
import { Card, CardContent, CardDivider, Flex, Skeleton, SkeletonBox, Text } from '@bitrise/bitkit';
|
|
3
|
-
import CodeBlock from '../../CodeBlock/CodeBlock';
|
|
4
|
-
import Section from '../../Section/Section';
|
|
5
|
-
|
|
6
|
-
const SectionSkeleton = () => {
|
|
7
|
-
return (
|
|
8
|
-
<Section>
|
|
9
|
-
<Text>
|
|
10
|
-
The Skeleton pattern is a great alternative to showing a loading spinner, by inserting similar shaped
|
|
11
|
-
placeholders to the content that will eventually be shown when it becomes available.
|
|
12
|
-
</Text>
|
|
13
|
-
|
|
14
|
-
<Flex direction="horizontal" gap="x6" margin="x6">
|
|
15
|
-
{Array.from({ length: 2 }).map((_, i) => (
|
|
16
|
-
<Flex grow initial="none" key={i}>
|
|
17
|
-
<Skeleton active>
|
|
18
|
-
<Card direction="vertical">
|
|
19
|
-
<CardContent padding="x4">
|
|
20
|
-
<SkeletonBox height="1.5rem" margin="x1" />
|
|
21
|
-
<SkeletonBox height="0.5rem" margin="x1" />
|
|
22
|
-
<SkeletonBox height="0.5rem" margin="x1" />
|
|
23
|
-
<SkeletonBox height="0.5rem" margin="x1" />
|
|
24
|
-
</CardContent>
|
|
25
|
-
<CardDivider />
|
|
26
|
-
<CardContent padding="x4">
|
|
27
|
-
<Flex direction="horizontal" gap="x6">
|
|
28
|
-
<Flex grow initial="none">
|
|
29
|
-
<SkeletonBox height="1.5rem" />
|
|
30
|
-
</Flex>
|
|
31
|
-
|
|
32
|
-
<Flex grow initial="none">
|
|
33
|
-
<SkeletonBox height="1.5rem" />
|
|
34
|
-
</Flex>
|
|
35
|
-
|
|
36
|
-
<Flex grow initial="none">
|
|
37
|
-
<SkeletonBox height="1.5rem" />
|
|
38
|
-
</Flex>
|
|
39
|
-
</Flex>
|
|
40
|
-
</CardContent>
|
|
41
|
-
</Card>
|
|
42
|
-
</Skeleton>
|
|
43
|
-
</Flex>
|
|
44
|
-
))}
|
|
45
|
-
</Flex>
|
|
46
|
-
|
|
47
|
-
<Flex direction="horizontal" gap="x6">
|
|
48
|
-
{Array.from({ length: 4 }).map((_, i) => (
|
|
49
|
-
<Flex grow initial="none" key={i}>
|
|
50
|
-
<Skeleton active>
|
|
51
|
-
<Card direction="vertical">
|
|
52
|
-
<CardContent padding="x4">
|
|
53
|
-
<SkeletonBox height="3rem" margin="x1" />
|
|
54
|
-
</CardContent>
|
|
55
|
-
<CardDivider />
|
|
56
|
-
<CardContent padding="x4">
|
|
57
|
-
<SkeletonBox height="0.25rem" margin="x1" />
|
|
58
|
-
<SkeletonBox height="0.25rem" margin="x1" />
|
|
59
|
-
<SkeletonBox height="0.25rem" margin="x1" />
|
|
60
|
-
</CardContent>
|
|
61
|
-
</Card>
|
|
62
|
-
</Skeleton>
|
|
63
|
-
</Flex>
|
|
64
|
-
))}
|
|
65
|
-
</Flex>
|
|
66
|
-
|
|
67
|
-
<CodeBlock title="Skeleton Usage Example">{`const Component = () => (
|
|
68
|
-
<Skeleton active>
|
|
69
|
-
<Card direction="vertical">
|
|
70
|
-
<CardContent padding="x4">
|
|
71
|
-
<SkeletonBox height="1.5rem" margin="x1" />
|
|
72
|
-
<SkeletonBox height="0.5rem" margin="x1" />
|
|
73
|
-
<SkeletonBox height="0.5rem" margin="x1" />
|
|
74
|
-
<SkeletonBox height="0.5rem" margin="x1" />
|
|
75
|
-
</CardContent>
|
|
76
|
-
<CardDivider />
|
|
77
|
-
<CardContent padding="x4">
|
|
78
|
-
<Flex direction="horizontal" gap="x6">
|
|
79
|
-
<Flex grow initial="none">
|
|
80
|
-
<SkeletonBox height="1.5rem" />
|
|
81
|
-
</Flex>
|
|
82
|
-
|
|
83
|
-
<Flex grow initial="none">
|
|
84
|
-
<SkeletonBox height="1.5rem" />
|
|
85
|
-
</Flex>
|
|
86
|
-
|
|
87
|
-
<Flex grow initial="none">
|
|
88
|
-
<SkeletonBox height="1.5rem" />
|
|
89
|
-
</Flex>
|
|
90
|
-
</Flex>
|
|
91
|
-
</CardContent>
|
|
92
|
-
</Card>
|
|
93
|
-
</Skeleton>
|
|
94
|
-
);`}</CodeBlock>
|
|
95
|
-
</Section>
|
|
96
|
-
);
|
|
97
|
-
};
|
|
98
|
-
|
|
99
|
-
export default SectionSkeleton;
|
|
@@ -1,53 +0,0 @@
|
|
|
1
|
-
import * as React from 'react';
|
|
2
|
-
import { Tabs, Tab } from '@bitrise/bitkit';
|
|
3
|
-
import SandboxFrame from '../../Sandbox/SandboxFrame';
|
|
4
|
-
import Section from '../../Section/Section';
|
|
5
|
-
import Window from '../../Window/Window';
|
|
6
|
-
|
|
7
|
-
const { useState } = React;
|
|
8
|
-
|
|
9
|
-
const SectionStatus = () => {
|
|
10
|
-
const [selectedTab, setSelectedTab] = useState(1);
|
|
11
|
-
|
|
12
|
-
return (
|
|
13
|
-
<Section>
|
|
14
|
-
<Tabs gap="x6" margin="x4">
|
|
15
|
-
<Tab active={selectedTab === 1} onClick={() => setSelectedTab(1)}>
|
|
16
|
-
404 - Not Found
|
|
17
|
-
</Tab>
|
|
18
|
-
|
|
19
|
-
<Tab active={selectedTab === 2} onClick={() => setSelectedTab(2)}>
|
|
20
|
-
500 - Server Error
|
|
21
|
-
</Tab>
|
|
22
|
-
</Tabs>
|
|
23
|
-
|
|
24
|
-
{selectedTab === 1 && (
|
|
25
|
-
<Window
|
|
26
|
-
backgroundColor="gray-1"
|
|
27
|
-
borderColor="gray-2"
|
|
28
|
-
borderWidth="x1"
|
|
29
|
-
elevation="x2"
|
|
30
|
-
textColor="grape-5"
|
|
31
|
-
title="404 - NotFound"
|
|
32
|
-
>
|
|
33
|
-
<SandboxFrame minHeight="600px" src="/sandbox/status404" />
|
|
34
|
-
</Window>
|
|
35
|
-
)}
|
|
36
|
-
|
|
37
|
-
{selectedTab === 2 && (
|
|
38
|
-
<Window
|
|
39
|
-
backgroundColor="gray-1"
|
|
40
|
-
borderColor="gray-2"
|
|
41
|
-
borderWidth="x1"
|
|
42
|
-
elevation="x2"
|
|
43
|
-
textColor="grape-5"
|
|
44
|
-
title="500 - Server Error"
|
|
45
|
-
>
|
|
46
|
-
<SandboxFrame minHeight="600px" src="/sandbox/status500" />
|
|
47
|
-
</Window>
|
|
48
|
-
)}
|
|
49
|
-
</Section>
|
|
50
|
-
);
|
|
51
|
-
};
|
|
52
|
-
|
|
53
|
-
export default SectionStatus;
|
|
@@ -1,42 +0,0 @@
|
|
|
1
|
-
import * as React from 'react';
|
|
2
|
-
import { hooks, AddonFooter, Base, ColorButton, Buttons, Flex, Status404, Text } from '@bitrise/bitkit';
|
|
3
|
-
|
|
4
|
-
const { useMediaQuery } = hooks;
|
|
5
|
-
|
|
6
|
-
const SectionStatus404Example = () => {
|
|
7
|
-
const match = useMediaQuery(['864px']);
|
|
8
|
-
|
|
9
|
-
return (
|
|
10
|
-
<Flex backgroundColor="grape-5" grow paddingVertical="x16" textColor="aqua-1">
|
|
11
|
-
<Status404 />
|
|
12
|
-
|
|
13
|
-
<Base paddingHorizontal="x6">
|
|
14
|
-
<Text align="middle" margin="x8" size="4" weight="bold">
|
|
15
|
-
Do you prefer the deep unkown, or looking for something else?
|
|
16
|
-
</Text>
|
|
17
|
-
|
|
18
|
-
<Buttons
|
|
19
|
-
alignChildren={match('864px') ? 'middle' : undefined}
|
|
20
|
-
fullWidth={!match('864px')}
|
|
21
|
-
gap={match('864px') ? 'x6' : 'x3'}
|
|
22
|
-
>
|
|
23
|
-
<ColorButton color="white" size="large">
|
|
24
|
-
Switch Account
|
|
25
|
-
</ColorButton>
|
|
26
|
-
|
|
27
|
-
<ColorButton color="white" size="large">
|
|
28
|
-
Learn Bitrise Tricks
|
|
29
|
-
</ColorButton>
|
|
30
|
-
|
|
31
|
-
<ColorButton color="white" size="large">
|
|
32
|
-
Check Open Positions
|
|
33
|
-
</ColorButton>
|
|
34
|
-
</Buttons>
|
|
35
|
-
</Base>
|
|
36
|
-
|
|
37
|
-
<AddonFooter addonName="Ship" margin="x16" />
|
|
38
|
-
</Flex>
|
|
39
|
-
);
|
|
40
|
-
};
|
|
41
|
-
|
|
42
|
-
export default SectionStatus404Example;
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
import * as React from 'react';
|
|
2
|
-
import { AddonFooter, Flex, Status500 } from '@bitrise/bitkit';
|
|
3
|
-
|
|
4
|
-
const SectionStatus500Example = () => {
|
|
5
|
-
return (
|
|
6
|
-
<Flex backgroundColor="grape-5" grow paddingVertical="x16" textColor="aqua-1">
|
|
7
|
-
<Status500 />
|
|
8
|
-
<AddonFooter addonName="Ship" margin="x16" />
|
|
9
|
-
</Flex>
|
|
10
|
-
);
|
|
11
|
-
};
|
|
12
|
-
|
|
13
|
-
export default SectionStatus500Example;
|
|
@@ -1,83 +0,0 @@
|
|
|
1
|
-
import * as React from 'react';
|
|
2
|
-
import {
|
|
3
|
-
Button,
|
|
4
|
-
Icon,
|
|
5
|
-
Table,
|
|
6
|
-
TableBody,
|
|
7
|
-
TableCell,
|
|
8
|
-
TableHeader,
|
|
9
|
-
TableHeaderCell,
|
|
10
|
-
TableHeaderRow,
|
|
11
|
-
TableRow,
|
|
12
|
-
Text,
|
|
13
|
-
Base,
|
|
14
|
-
} from '@bitrise/bitkit';
|
|
15
|
-
import Section from '../../Section/Section';
|
|
16
|
-
import SectionSubTitle from '../../Section/SectionSubTitle';
|
|
17
|
-
|
|
18
|
-
const SectionTable = () => {
|
|
19
|
-
return (
|
|
20
|
-
<Section>
|
|
21
|
-
<Base margin="x6">
|
|
22
|
-
<SectionSubTitle>Card Table</SectionSubTitle>
|
|
23
|
-
<Table type="card">
|
|
24
|
-
<TableHeader>
|
|
25
|
-
<TableHeaderRow>
|
|
26
|
-
<TableHeaderCell>Trace Name</TableHeaderCell>
|
|
27
|
-
<TableHeaderCell align="middle">Duration</TableHeaderCell>
|
|
28
|
-
<TableHeaderCell align="middle">Sample</TableHeaderCell>
|
|
29
|
-
<TableHeaderCell />
|
|
30
|
-
</TableHeaderRow>
|
|
31
|
-
</TableHeader>
|
|
32
|
-
|
|
33
|
-
<TableBody>
|
|
34
|
-
{Array.from({ length: 10 }).map((_, i) => (
|
|
35
|
-
<TableRow key={i}>
|
|
36
|
-
<TableCell>UIControllerName</TableCell>
|
|
37
|
-
<TableCell align="middle">23 443 sec</TableCell>
|
|
38
|
-
<TableCell align="middle">12 987</TableCell>
|
|
39
|
-
<TableCell shrink>
|
|
40
|
-
<Button level="tertiary" size="small">
|
|
41
|
-
<Text>Details</Text>
|
|
42
|
-
<Icon name="ArrowForward" />
|
|
43
|
-
</Button>
|
|
44
|
-
</TableCell>
|
|
45
|
-
</TableRow>
|
|
46
|
-
))}
|
|
47
|
-
</TableBody>
|
|
48
|
-
</Table>
|
|
49
|
-
</Base>
|
|
50
|
-
<Base margin="x12">
|
|
51
|
-
<SectionSubTitle>Flat Table</SectionSubTitle>
|
|
52
|
-
<Table type="flat">
|
|
53
|
-
<TableHeader>
|
|
54
|
-
<TableHeaderRow>
|
|
55
|
-
<TableHeaderCell>Trace Name</TableHeaderCell>
|
|
56
|
-
<TableHeaderCell align="middle">Duration</TableHeaderCell>
|
|
57
|
-
<TableHeaderCell align="middle">Sample</TableHeaderCell>
|
|
58
|
-
<TableHeaderCell />
|
|
59
|
-
</TableHeaderRow>
|
|
60
|
-
</TableHeader>
|
|
61
|
-
|
|
62
|
-
<TableBody>
|
|
63
|
-
{Array.from({ length: 10 }).map((_, i) => (
|
|
64
|
-
<TableRow key={i}>
|
|
65
|
-
<TableCell>UIControllerName</TableCell>
|
|
66
|
-
<TableCell align="middle">23 443 sec</TableCell>
|
|
67
|
-
<TableCell align="middle">12 987</TableCell>
|
|
68
|
-
<TableCell shrink>
|
|
69
|
-
<Button level="tertiary" size="small">
|
|
70
|
-
<Text>Details</Text>
|
|
71
|
-
<Icon name="ArrowForward" />
|
|
72
|
-
</Button>
|
|
73
|
-
</TableCell>
|
|
74
|
-
</TableRow>
|
|
75
|
-
))}
|
|
76
|
-
</TableBody>
|
|
77
|
-
</Table>
|
|
78
|
-
</Base>
|
|
79
|
-
</Section>
|
|
80
|
-
);
|
|
81
|
-
};
|
|
82
|
-
|
|
83
|
-
export default SectionTable;
|
|
@@ -1,25 +0,0 @@
|
|
|
1
|
-
import * as React from 'react';
|
|
2
|
-
import { Tab, Tabs } from '@bitrise/bitkit';
|
|
3
|
-
import Section from '../../Section/Section';
|
|
4
|
-
|
|
5
|
-
const { useState } = React;
|
|
6
|
-
|
|
7
|
-
const SectionTabs = () => {
|
|
8
|
-
const [active, setActive] = useState(0);
|
|
9
|
-
|
|
10
|
-
return (
|
|
11
|
-
<Section>
|
|
12
|
-
<Tabs>
|
|
13
|
-
<Tab active={active === 0} onClick={() => setActive(0)}>
|
|
14
|
-
Metrics
|
|
15
|
-
</Tab>
|
|
16
|
-
|
|
17
|
-
<Tab active={active === 1} onClick={() => setActive(1)}>
|
|
18
|
-
Sessions
|
|
19
|
-
</Tab>
|
|
20
|
-
</Tabs>
|
|
21
|
-
</Section>
|
|
22
|
-
);
|
|
23
|
-
};
|
|
24
|
-
|
|
25
|
-
export default SectionTabs;
|
|
@@ -1,34 +0,0 @@
|
|
|
1
|
-
import * as React from 'react';
|
|
2
|
-
import { Text } from '@bitrise/bitkit';
|
|
3
|
-
import CodeBlock from '../../CodeBlock/CodeBlock';
|
|
4
|
-
import Section from '../../Section/Section';
|
|
5
|
-
|
|
6
|
-
const SectionText = () => {
|
|
7
|
-
return (
|
|
8
|
-
<Section paddingVertical="x8">
|
|
9
|
-
<Text align="middle" margin="x2" size="6" weight="bold">
|
|
10
|
-
The spectacle before us was indeed sublime.
|
|
11
|
-
</Text>
|
|
12
|
-
<Text align="middle" margin="x2">
|
|
13
|
-
Apparently we had reached a great height in the atmosphere, for the sky was a dead black, and the stars had
|
|
14
|
-
ceased to twinkle. By the same illusion which lifts the horizon of the sea to the level of the spectator on a
|
|
15
|
-
hillside, the sable cloud beneath was dished out, and the car seemed to float in the middle of an immense dark
|
|
16
|
-
sphere, whose upper half was strewn with silver. Looking down into the dark gulf below, I could see a ruddy
|
|
17
|
-
light streaming through a rift in the clouds.
|
|
18
|
-
</Text>
|
|
19
|
-
<Text align="middle" margin="x4" size="6" uppercase weight="bold">
|
|
20
|
-
Bitbot
|
|
21
|
-
</Text>
|
|
22
|
-
|
|
23
|
-
<CodeBlock title="Text Usage Example">{`const Component = () => (
|
|
24
|
-
<React.Fragment>
|
|
25
|
-
<Text align="middle" margin="x2" size="6" weight="bold">...</Text>
|
|
26
|
-
<Text align="middle" margin="x2" size="7">...</Text>
|
|
27
|
-
<Text align="middle" margin="x4" size="6" weight="bold">...</Text>
|
|
28
|
-
</React.Fragment>
|
|
29
|
-
);`}</CodeBlock>
|
|
30
|
-
</Section>
|
|
31
|
-
);
|
|
32
|
-
};
|
|
33
|
-
|
|
34
|
-
export default SectionText;
|
|
@@ -1,43 +0,0 @@
|
|
|
1
|
-
import * as React from 'react';
|
|
2
|
-
import { Textarea, Base, InputLabel, InputInlineHelp } from '@bitrise/bitkit';
|
|
3
|
-
import SectionSubTitle from '../../Section/SectionSubTitle';
|
|
4
|
-
import CodeBlock from '../../CodeBlock/CodeBlock';
|
|
5
|
-
import Section from '../../Section/Section';
|
|
6
|
-
|
|
7
|
-
const SectionTextarea = () => {
|
|
8
|
-
return (
|
|
9
|
-
<Section>
|
|
10
|
-
<Base margin="x6">
|
|
11
|
-
<SectionSubTitle>Simple text area</SectionSubTitle>
|
|
12
|
-
|
|
13
|
-
<Textarea />
|
|
14
|
-
</Base>
|
|
15
|
-
|
|
16
|
-
<Base margin="x6">
|
|
17
|
-
<SectionSubTitle>Text area with input label and inline help</SectionSubTitle>
|
|
18
|
-
|
|
19
|
-
<InputLabel>How could be improve our services? *</InputLabel>
|
|
20
|
-
<Textarea placeholder="Your feedback" />
|
|
21
|
-
<InputInlineHelp>* Type in at least 8 characters</InputInlineHelp>
|
|
22
|
-
</Base>
|
|
23
|
-
|
|
24
|
-
<CodeBlock title="Textarea usage example">{`const Component = () => (
|
|
25
|
-
<Flex margin="x3">
|
|
26
|
-
<InputLabel>
|
|
27
|
-
How could be improve our services? *
|
|
28
|
-
</InputLabel>
|
|
29
|
-
|
|
30
|
-
<Textarea placeholder="Your feedback">
|
|
31
|
-
My awesome feedback
|
|
32
|
-
</Textarea>
|
|
33
|
-
|
|
34
|
-
<InputInlineHelp>
|
|
35
|
-
* Type in at least 8 characters
|
|
36
|
-
</InputInlineHelp>
|
|
37
|
-
</Flex>
|
|
38
|
-
);`}</CodeBlock>
|
|
39
|
-
</Section>
|
|
40
|
-
);
|
|
41
|
-
};
|
|
42
|
-
|
|
43
|
-
export default SectionTextarea;
|
|
@@ -1,50 +0,0 @@
|
|
|
1
|
-
import * as React from 'react';
|
|
2
|
-
import { hooks, Toggle, Flex } from '@bitrise/bitkit';
|
|
3
|
-
|
|
4
|
-
import Section from '../../Section/Section';
|
|
5
|
-
import SectionSubTitle from '../../Section/SectionSubTitle';
|
|
6
|
-
import CodeBlock from '../../CodeBlock/CodeBlock';
|
|
7
|
-
|
|
8
|
-
const { useMediaQuery } = hooks;
|
|
9
|
-
|
|
10
|
-
const SectionToggle = () => {
|
|
11
|
-
const match = useMediaQuery(['896px']);
|
|
12
|
-
|
|
13
|
-
return (
|
|
14
|
-
<Section>
|
|
15
|
-
<Flex direction={match('896px') ? 'horizontal' : 'vertical'} gap="x12" margin="x12">
|
|
16
|
-
<Flex grow initial={match('896px') ? 'none' : 'content'}>
|
|
17
|
-
<SectionSubTitle>Checked Toggle</SectionSubTitle>
|
|
18
|
-
<Toggle defaultChecked>Label</Toggle>
|
|
19
|
-
</Flex>
|
|
20
|
-
|
|
21
|
-
<Flex grow initial={match('896px') ? 'none' : 'content'}>
|
|
22
|
-
<SectionSubTitle>Unchecked Toggle</SectionSubTitle>
|
|
23
|
-
<Toggle>Label</Toggle>
|
|
24
|
-
</Flex>
|
|
25
|
-
|
|
26
|
-
<Flex grow initial={match('896px') ? 'none' : 'content'}>
|
|
27
|
-
<SectionSubTitle>Disabled & checked Toggle</SectionSubTitle>
|
|
28
|
-
<Toggle defaultChecked disabled>
|
|
29
|
-
Label
|
|
30
|
-
</Toggle>
|
|
31
|
-
</Flex>
|
|
32
|
-
|
|
33
|
-
<Flex grow initial={match('896px') ? 'none' : 'content'}>
|
|
34
|
-
<SectionSubTitle>Disabled & unchecked Toggle</SectionSubTitle>
|
|
35
|
-
<Toggle disabled>Label</Toggle>
|
|
36
|
-
</Flex>
|
|
37
|
-
</Flex>
|
|
38
|
-
|
|
39
|
-
<CodeBlock title="Toggle usage example">{`const Component = () => (
|
|
40
|
-
const [checked, setChecked] = useState(false);
|
|
41
|
-
|
|
42
|
-
<Toggle checked={ checked } onChange={ () => setChecked(!checked) }>
|
|
43
|
-
Label
|
|
44
|
-
</Toggle>
|
|
45
|
-
);`}</CodeBlock>
|
|
46
|
-
</Section>
|
|
47
|
-
);
|
|
48
|
-
};
|
|
49
|
-
|
|
50
|
-
export default SectionToggle;
|
|
@@ -1,50 +0,0 @@
|
|
|
1
|
-
import * as React from 'react';
|
|
2
|
-
import { hooks, Button, Flex, Icon, Tooltip } from '@bitrise/bitkit';
|
|
3
|
-
import Section from '../../Section/Section';
|
|
4
|
-
import SectionSubTitle from '../../Section/SectionSubTitle';
|
|
5
|
-
|
|
6
|
-
const { useState } = React;
|
|
7
|
-
const { useMediaQuery } = hooks;
|
|
8
|
-
|
|
9
|
-
const SectionTooltips = () => {
|
|
10
|
-
const [visible, setVisible] = useState(false);
|
|
11
|
-
const match = useMediaQuery(['896px']);
|
|
12
|
-
|
|
13
|
-
return (
|
|
14
|
-
<Section>
|
|
15
|
-
<Flex direction={match('896px') ? 'horizontal' : 'vertical'} gap="x12" margin="x6">
|
|
16
|
-
<Flex grow initial={match('896px') ? 'none' : 'content'}>
|
|
17
|
-
<SectionSubTitle>Uncontrolled (Mouseover)</SectionSubTitle>
|
|
18
|
-
|
|
19
|
-
<Flex direction="horizontal" gap="x6">
|
|
20
|
-
<Flex>
|
|
21
|
-
<Tooltip title="React!">
|
|
22
|
-
{({ ref, ...rest }) => <Icon {...rest} innerRef={ref} name="PlatformsReact" size="3rem" />}
|
|
23
|
-
</Tooltip>
|
|
24
|
-
</Flex>
|
|
25
|
-
|
|
26
|
-
<Flex>
|
|
27
|
-
<Tooltip title="Woooooooooooooow">
|
|
28
|
-
{({ ref, ...rest }) => <Icon {...rest} innerRef={ref} name="Wow" size="3rem" />}
|
|
29
|
-
</Tooltip>
|
|
30
|
-
</Flex>
|
|
31
|
-
</Flex>
|
|
32
|
-
</Flex>
|
|
33
|
-
|
|
34
|
-
<Flex grow initial={match('896px') ? 'none' : 'content'}>
|
|
35
|
-
<SectionSubTitle>Controlled (with state)</SectionSubTitle>
|
|
36
|
-
|
|
37
|
-
<Tooltip title="I'm being controlled!" visible={visible}>
|
|
38
|
-
{({ ref }) => (
|
|
39
|
-
<Button innerRef={ref} level="primary" onClick={() => setVisible(!visible)}>
|
|
40
|
-
{visible ? 'Hide Tooltip' : 'Show Tooltip'}
|
|
41
|
-
</Button>
|
|
42
|
-
)}
|
|
43
|
-
</Tooltip>
|
|
44
|
-
</Flex>
|
|
45
|
-
</Flex>
|
|
46
|
-
</Section>
|
|
47
|
-
);
|
|
48
|
-
};
|
|
49
|
-
|
|
50
|
-
export default SectionTooltips;
|