@primer/components 0.0.0-20219150508 → 0.0.0-202191514926
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/CHANGELOG.md +1 -1
- package/dist/browser.esm.js +69 -69
- package/dist/browser.esm.js.map +1 -1
- package/dist/browser.umd.js +28 -28
- package/dist/browser.umd.js.map +1 -1
- package/lib/ActionList/Header.js +1 -1
- package/lib/ActionList/Item.js +7 -7
- package/lib/ActionList2/Description.d.ts +5 -0
- package/lib/ActionList2/Description.js +54 -0
- package/lib/ActionList2/Divider.d.ts +8 -0
- package/lib/ActionList2/Divider.js +42 -0
- package/lib/ActionList2/Group.d.ts +8 -0
- package/lib/ActionList2/Group.js +39 -0
- package/lib/ActionList2/Header.d.ts +26 -0
- package/lib/ActionList2/Header.js +55 -0
- package/lib/ActionList2/Item.d.ts +53 -0
- package/lib/ActionList2/Item.js +188 -0
- package/lib/ActionList2/List.d.ts +18 -0
- package/lib/ActionList2/List.js +52 -0
- package/lib/ActionList2/Selection.d.ts +5 -0
- package/lib/ActionList2/Selection.js +67 -0
- package/lib/ActionList2/Visuals.d.ts +12 -0
- package/lib/ActionList2/Visuals.js +91 -0
- package/lib/ActionList2/hacks.d.ts +30 -0
- package/lib/ActionList2/hacks.js +38 -0
- package/lib/ActionList2/index.d.ts +26 -0
- package/lib/ActionList2/index.js +36 -0
- package/lib/BranchName.js +1 -1
- package/lib/Breadcrumbs.js +1 -1
- package/lib/Button/Button.js +1 -1
- package/lib/Button/ButtonClose.js +1 -1
- package/lib/Button/ButtonInvisible.js +1 -1
- package/lib/Button/ButtonTableList.js +1 -1
- package/lib/Dialog/ConfirmationDialog.js +1 -1
- package/lib/Dialog/Dialog.js +2 -2
- package/lib/FilterList.js +1 -1
- package/lib/Label.js +1 -1
- package/lib/Link.js +1 -1
- package/lib/Pagination/Pagination.js +1 -1
- package/lib/SelectMenu/SelectMenuDivider.js +1 -1
- package/lib/SelectMenu/SelectMenuFooter.js +1 -1
- package/lib/SelectMenu/SelectMenuItem.js +1 -1
- package/lib/SelectMenu/SelectMenuTab.js +1 -1
- package/lib/SubNav.js +1 -1
- package/lib/Timeline.js +2 -2
- package/lib/Token/Token.js +1 -1
- package/lib/UnderlineNav.js +1 -1
- package/lib/_TextInputWrapper.js +1 -1
- package/lib-esm/ActionList/Header.js +1 -1
- package/lib-esm/ActionList/Item.js +7 -7
- package/lib-esm/ActionList2/Description.d.ts +5 -0
- package/lib-esm/ActionList2/Description.js +38 -0
- package/lib-esm/ActionList2/Divider.d.ts +8 -0
- package/lib-esm/ActionList2/Divider.js +30 -0
- package/lib-esm/ActionList2/Group.d.ts +8 -0
- package/lib-esm/ActionList2/Group.js +29 -0
- package/lib-esm/ActionList2/Header.d.ts +26 -0
- package/lib-esm/ActionList2/Header.js +45 -0
- package/lib-esm/ActionList2/Item.d.ts +53 -0
- package/lib-esm/ActionList2/Item.js +185 -0
- package/lib-esm/ActionList2/List.d.ts +18 -0
- package/lib-esm/ActionList2/List.js +42 -0
- package/lib-esm/ActionList2/Selection.d.ts +5 -0
- package/lib-esm/ActionList2/Selection.js +50 -0
- package/lib-esm/ActionList2/Visuals.d.ts +12 -0
- package/lib-esm/ActionList2/Visuals.js +68 -0
- package/lib-esm/ActionList2/hacks.d.ts +30 -0
- package/lib-esm/ActionList2/hacks.js +30 -0
- package/lib-esm/ActionList2/index.d.ts +26 -0
- package/lib-esm/ActionList2/index.js +23 -0
- package/lib-esm/BranchName.js +1 -1
- package/lib-esm/Breadcrumbs.js +1 -1
- package/lib-esm/Button/Button.js +1 -1
- package/lib-esm/Button/ButtonClose.js +1 -1
- package/lib-esm/Button/ButtonInvisible.js +1 -1
- package/lib-esm/Button/ButtonTableList.js +1 -1
- package/lib-esm/Dialog/ConfirmationDialog.js +1 -1
- package/lib-esm/Dialog/Dialog.js +2 -2
- package/lib-esm/FilterList.js +1 -1
- package/lib-esm/Label.js +1 -1
- package/lib-esm/Link.js +1 -1
- package/lib-esm/Pagination/Pagination.js +1 -1
- package/lib-esm/SelectMenu/SelectMenuDivider.js +1 -1
- package/lib-esm/SelectMenu/SelectMenuFooter.js +1 -1
- package/lib-esm/SelectMenu/SelectMenuItem.js +1 -1
- package/lib-esm/SelectMenu/SelectMenuTab.js +1 -1
- package/lib-esm/SubNav.js +1 -1
- package/lib-esm/Timeline.js +2 -2
- package/lib-esm/Token/Token.js +1 -1
- package/lib-esm/UnderlineNav.js +1 -1
- package/lib-esm/_TextInputWrapper.js +1 -1
- package/package.json +1 -1
@@ -0,0 +1,30 @@
|
|
1
|
+
/**
|
2
|
+
* These colors are not yet in our default theme.
|
3
|
+
* TODO: Need to remove this once they are added.
|
4
|
+
*/
|
5
|
+
export declare const customItemThemes: {
|
6
|
+
default: {
|
7
|
+
hover: {
|
8
|
+
light: string;
|
9
|
+
dark: string;
|
10
|
+
dark_dimmed: string;
|
11
|
+
};
|
12
|
+
focus: {
|
13
|
+
light: string;
|
14
|
+
dark: string;
|
15
|
+
dark_dimmed: string;
|
16
|
+
};
|
17
|
+
};
|
18
|
+
danger: {
|
19
|
+
hover: {
|
20
|
+
light: string;
|
21
|
+
dark: string;
|
22
|
+
dark_dimmed: string;
|
23
|
+
};
|
24
|
+
focus: {
|
25
|
+
light: string;
|
26
|
+
dark: string;
|
27
|
+
dark_dimmed: string;
|
28
|
+
};
|
29
|
+
};
|
30
|
+
};
|
@@ -0,0 +1,30 @@
|
|
1
|
+
/**
|
2
|
+
* These colors are not yet in our default theme.
|
3
|
+
* TODO: Need to remove this once they are added.
|
4
|
+
*/
|
5
|
+
export const customItemThemes = {
|
6
|
+
default: {
|
7
|
+
hover: {
|
8
|
+
light: 'rgba(46, 77, 108, 0.06)',
|
9
|
+
dark: 'rgba(201, 206, 212, 0.12)',
|
10
|
+
dark_dimmed: 'rgba(201, 206, 212, 0.12)'
|
11
|
+
},
|
12
|
+
focus: {
|
13
|
+
light: 'rgba(54, 77, 100, 0.16)',
|
14
|
+
dark: 'rgba(201, 206, 212, 0.24)',
|
15
|
+
dark_dimmed: 'rgba(201, 206, 212, 0.24)'
|
16
|
+
}
|
17
|
+
},
|
18
|
+
danger: {
|
19
|
+
hover: {
|
20
|
+
light: 'rgba(234, 74, 90, 0.08)',
|
21
|
+
dark: 'rgba(248, 81, 73, 0.16)',
|
22
|
+
dark_dimmed: 'rgba(248, 81, 73, 0.16)'
|
23
|
+
},
|
24
|
+
focus: {
|
25
|
+
light: 'rgba(234, 74, 90, 0.14)',
|
26
|
+
dark: 'rgba(248, 81, 73, 0.24)',
|
27
|
+
dark_dimmed: 'rgba(248, 81, 73, 0.24)'
|
28
|
+
}
|
29
|
+
}
|
30
|
+
};
|
@@ -0,0 +1,26 @@
|
|
1
|
+
/// <reference types="react" />
|
2
|
+
import { Group } from './Group';
|
3
|
+
import { Divider } from './Divider';
|
4
|
+
export type { ListProps as ActionListProps } from './List';
|
5
|
+
export type { GroupProps } from './Group';
|
6
|
+
export type { ItemProps } from './Item';
|
7
|
+
export type { DescriptionProps } from './Description';
|
8
|
+
export type { LeadingVisualProps, TrailingVisualProps } from './Visuals';
|
9
|
+
/**
|
10
|
+
* Collection of list-related components.
|
11
|
+
*/
|
12
|
+
export declare const ActionList: import("@radix-ui/react-polymorphic").ForwardRefComponent<"ul", import("./List").ListProps> & {
|
13
|
+
/** Collects related `Items` in an `ActionList`. */
|
14
|
+
Group: typeof Group;
|
15
|
+
/** An actionable or selectable `Item` with an optional icon and description. */
|
16
|
+
Item: import("@radix-ui/react-polymorphic").ForwardRefComponent<"li", import("./Item").ItemProps>;
|
17
|
+
/** Visually separates `Item`s or `Group`s in an `ActionList`. */
|
18
|
+
Divider: typeof Divider;
|
19
|
+
Description: import("react").FC<import("./Description").DescriptionProps>;
|
20
|
+
LeadingVisual: import("react").FC<Pick<import("./Item").ItemProps, "sx" | "disabled" | "variant"> & {
|
21
|
+
children: import("react").ReactNode;
|
22
|
+
}>;
|
23
|
+
TrailingVisual: import("react").FC<Pick<import("./Item").ItemProps, "sx" | "disabled" | "variant"> & {
|
24
|
+
children: import("react").ReactNode;
|
25
|
+
}>;
|
26
|
+
};
|
@@ -0,0 +1,23 @@
|
|
1
|
+
import { List } from './List';
|
2
|
+
import { Group } from './Group';
|
3
|
+
import { Item } from './Item';
|
4
|
+
import { Divider } from './Divider';
|
5
|
+
import { Description } from './Description';
|
6
|
+
import { LeadingVisual, TrailingVisual } from './Visuals';
|
7
|
+
|
8
|
+
/**
|
9
|
+
* Collection of list-related components.
|
10
|
+
*/
|
11
|
+
export const ActionList = Object.assign(List, {
|
12
|
+
/** Collects related `Items` in an `ActionList`. */
|
13
|
+
Group,
|
14
|
+
|
15
|
+
/** An actionable or selectable `Item` with an optional icon and description. */
|
16
|
+
Item,
|
17
|
+
|
18
|
+
/** Visually separates `Item`s or `Group`s in an `ActionList`. */
|
19
|
+
Divider,
|
20
|
+
Description,
|
21
|
+
LeadingVisual,
|
22
|
+
TrailingVisual
|
23
|
+
});
|
package/lib-esm/BranchName.js
CHANGED
@@ -4,5 +4,5 @@ import sx from './sx';
|
|
4
4
|
const BranchName = styled.a.withConfig({
|
5
5
|
displayName: "BranchName",
|
6
6
|
componentId: "sc-167ouzm-0"
|
7
|
-
})(["display:inline-block;padding:2px 6px;font-size:", ";font-family:", ";color:", ";background-color:", ";border-radius:", ";", ";", ";"], get('fontSizes.0'), get('fonts.mono'), get('colors.
|
7
|
+
})(["display:inline-block;padding:2px 6px;font-size:", ";font-family:", ";color:", ";background-color:", ";border-radius:", ";", ";", ";"], get('fontSizes.0'), get('fonts.mono'), get('colors.fg.muted'), get('colors.accent.subtle'), get('radii.2'), COMMON, sx);
|
8
8
|
export default BranchName;
|
package/lib-esm/Breadcrumbs.js
CHANGED
@@ -11,7 +11,7 @@ const SELECTED_CLASS = 'selected';
|
|
11
11
|
const Wrapper = styled.li.withConfig({
|
12
12
|
displayName: "Breadcrumbs__Wrapper",
|
13
13
|
componentId: "hwwoo0-0"
|
14
|
-
})(["display:inline-block;white-space:nowrap;list-style:none;&::after{padding-right:0.5em;padding-left:0.5em;color:", ";font-size:", ";content:'/';}&:first-child{margin-left:0;}&:last-child{&::after{content:none;}}"], get('colors.
|
14
|
+
})(["display:inline-block;white-space:nowrap;list-style:none;&::after{padding-right:0.5em;padding-left:0.5em;color:", ";font-size:", ";content:'/';}&:first-child{margin-left:0;}&:last-child{&::after{content:none;}}"], get('colors.fg.muted'), get('fontSizes.1'));
|
15
15
|
const BreadcrumbsBase = styled.nav.withConfig({
|
16
16
|
displayName: "Breadcrumbs__BreadcrumbsBase",
|
17
17
|
componentId: "hwwoo0-1"
|
package/lib-esm/Button/Button.js
CHANGED
@@ -5,5 +5,5 @@ import ButtonBase, { buttonSystemProps } from './ButtonBase';
|
|
5
5
|
const Button = styled(ButtonBase).withConfig({
|
6
6
|
displayName: "Button",
|
7
7
|
componentId: "xjtz72-0"
|
8
|
-
})(["color:", ";background-color:", ";border:1px solid ", ";box-shadow:", ",", "};&:hover{background-color:", ";border-color:", ";}&:focus{border-color:", ";box-shadow:", ";}&:active{background-color:", ";box-shadow:", ";}&:disabled{color:", ";background-color:", ";border-color:", ";}", ";", ";"], get('colors.btn.text'), get('colors.btn.bg'), get('colors.btn.border'), get('shadows.btn.shadow'), get('shadows.btn.insetShadow'), get('colors.btn.hoverBg'), get('colors.btn.hoverBorder'), get('colors.btn.focusBorder'), get('shadows.btn.focusShadow'), get('colors.btn.selectedBg'), get('shadows.btn.shadowActive'), get('colors.
|
8
|
+
})(["color:", ";background-color:", ";border:1px solid ", ";box-shadow:", ",", "};&:hover{background-color:", ";border-color:", ";}&:focus{border-color:", ";box-shadow:", ";}&:active{background-color:", ";box-shadow:", ";}&:disabled{color:", ";background-color:", ";border-color:", ";}", ";", ";"], get('colors.btn.text'), get('colors.btn.bg'), get('colors.btn.border'), get('shadows.btn.shadow'), get('shadows.btn.insetShadow'), get('colors.btn.hoverBg'), get('colors.btn.hoverBorder'), get('colors.btn.focusBorder'), get('shadows.btn.focusShadow'), get('colors.btn.selectedBg'), get('shadows.btn.shadowActive'), get('colors.fg.muted'), get('colors.btn.bg'), get('colors.btn.border'), buttonSystemProps, sx);
|
9
9
|
export default Button;
|
@@ -8,7 +8,7 @@ import sx from '../sx';
|
|
8
8
|
const StyledButton = styled.button.withConfig({
|
9
9
|
displayName: "ButtonClose__StyledButton",
|
10
10
|
componentId: "sc-13mzqph-0"
|
11
|
-
})(["border:none;padding:0;background:transparent;outline:none;cursor:pointer;border-radius:", ";color:", ";&:focus{box-shadow:", ";}&:hover{color:", ";}", ";", ";", ";"], get('radii.2'), get('colors.
|
11
|
+
})(["border:none;padding:0;background:transparent;outline:none;cursor:pointer;border-radius:", ";color:", ";&:focus{box-shadow:", ";}&:hover{color:", ";}", ";", ";", ";"], get('radii.2'), get('colors.fg.muted'), get('shadows.btn.focusShadow'), get('colors.accent.fg'), COMMON, LAYOUT, sx);
|
12
12
|
const ButtonClose = /*#__PURE__*/forwardRef((props, ref) => {
|
13
13
|
return /*#__PURE__*/React.createElement(StyledButton, _extends({
|
14
14
|
ref: ref,
|
@@ -5,5 +5,5 @@ import ButtonBase, { buttonSystemProps } from './ButtonBase';
|
|
5
5
|
const ButtonInvisible = styled(ButtonBase).withConfig({
|
6
6
|
displayName: "ButtonInvisible",
|
7
7
|
componentId: "sc-1195tpn-0"
|
8
|
-
})(["color:", ";background-color:transparent;border:0;border-radius:", ";box-shadow:none;&:disabled{color:", ";}&:focus{box-shadow:", ";}", ";", ""], get('colors.accent.fg'), get('radii.2'), get('colors.
|
8
|
+
})(["color:", ";background-color:transparent;border:0;border-radius:", ";box-shadow:none;&:disabled{color:", ";}&:focus{box-shadow:", ";}", ";", ""], get('colors.accent.fg'), get('radii.2'), get('colors.fg.muted'), get('shadows.btn.focusShadow'), buttonSystemProps, sx);
|
9
9
|
export default ButtonInvisible;
|
@@ -4,5 +4,5 @@ import sx from '../sx';
|
|
4
4
|
const ButtonTableList = styled.summary.withConfig({
|
5
5
|
displayName: "ButtonTableList",
|
6
6
|
componentId: "sc-1m4q8ia-0"
|
7
|
-
})(["display:inline-block;padding:0;font-size:", ";color:", ";text-decoration:none;white-space:nowrap;cursor:pointer;user-select:none;background-color:transparent;border:0;appearance:none;&:hover{text-decoration:underline;}&:disabled{&,&:hover{color:rgba(", ",0.5);cursor:default;}}&:after{display:inline-block;margin-left:", ";width:0;height:0;vertical-align:-2px;content:'';border:4px solid transparent;border-top-color:currentcolor;}", " ", " ", " ", ";"], get('fontSizes.1'), get('colors.
|
7
|
+
})(["display:inline-block;padding:0;font-size:", ";color:", ";text-decoration:none;white-space:nowrap;cursor:pointer;user-select:none;background-color:transparent;border:0;appearance:none;&:hover{text-decoration:underline;}&:disabled{&,&:hover{color:rgba(", ",0.5);cursor:default;}}&:after{display:inline-block;margin-left:", ";width:0;height:0;vertical-align:-2px;content:'';border:4px solid transparent;border-top-color:currentcolor;}", " ", " ", " ", ";"], get('fontSizes.1'), get('colors.fg.muted'), get('colors.fg.muted'), get('space.1'), COMMON, TYPOGRAPHY, LAYOUT, sx);
|
8
8
|
export default ButtonTableList;
|
@@ -41,7 +41,7 @@ ConfirmationHeader.displayName = "ConfirmationHeader";
|
|
41
41
|
const StyledConfirmationBody = styled(Box).withConfig({
|
42
42
|
displayName: "ConfirmationDialog__StyledConfirmationBody",
|
43
43
|
componentId: "sc-1ub32x2-2"
|
44
|
-
})(["font-size:", ";padding:0 ", " ", " ", ";color:", ";flex-grow:1;"], get('fontSizes.1'), get('space.3'), get('space.3'), get('space.3'), get('colors.
|
44
|
+
})(["font-size:", ";padding:0 ", " ", " ", ";color:", ";flex-grow:1;"], get('fontSizes.1'), get('space.3'), get('space.3'), get('space.3'), get('colors.fg.muted'));
|
45
45
|
|
46
46
|
const ConfirmationBody = ({
|
47
47
|
children
|
package/lib-esm/Dialog/Dialog.js
CHANGED
@@ -173,7 +173,7 @@ const Title = styled(Box).withConfig({
|
|
173
173
|
const Subtitle = styled(Box).withConfig({
|
174
174
|
displayName: "Dialog__Subtitle",
|
175
175
|
componentId: "sc-11pkgky-4"
|
176
|
-
})(["font-size:", ";margin-top:", ";color:", ";"], get('fontSizes.0'), get('space.1'), get('colors.
|
176
|
+
})(["font-size:", ";margin-top:", ";color:", ";"], get('fontSizes.0'), get('space.1'), get('colors.fg.muted'));
|
177
177
|
const Body = styled(Box).withConfig({
|
178
178
|
displayName: "Dialog__Body",
|
179
179
|
componentId: "sc-11pkgky-5"
|
@@ -227,7 +227,7 @@ const Buttons = ({
|
|
227
227
|
const DialogCloseButton = styled(Button).withConfig({
|
228
228
|
displayName: "Dialog__DialogCloseButton",
|
229
229
|
componentId: "sc-11pkgky-7"
|
230
|
-
})(["border-radius:4px;background:transparent;border:0;vertical-align:middle;color:", ";padding:", ";align-self:flex-start;line-height:normal;box-shadow:none;"], get('colors.
|
230
|
+
})(["border-radius:4px;background:transparent;border:0;vertical-align:middle;color:", ";padding:", ";align-self:flex-start;line-height:normal;box-shadow:none;"], get('colors.fg.muted'), get('space.2'));
|
231
231
|
|
232
232
|
const CloseButton = ({
|
233
233
|
onClose
|
package/lib-esm/FilterList.js
CHANGED
@@ -21,7 +21,7 @@ FilterList.displayName = "FilterList";
|
|
21
21
|
const FilterListItemBase = styled.a.withConfig({
|
22
22
|
displayName: "FilterList__FilterListItemBase",
|
23
23
|
componentId: "sc-1l4pxmz-1"
|
24
|
-
})(["position:relative;display:block;padding:", ";margin:", ";overflow:hidden;font-size:", ";color:", ";background-color:", "!important;text-decoration:none;text-overflow:ellipsis;white-space:nowrap;cursor:pointer;border-radius:", ";&:hover{text-decoration:none;background-color:", ";}&:active{color:", ";background-color:", ";}.count{float:right;font-weight:", ";}", ";", ";"], props => props.small ? `${get('space.1')(props)} 10px` : `${get('space.2')(props)} 11px`, props => props.small ? '0 0 2px' : '0 0 5px 0', get('fontSizes.1'), props => props.selected ? get('colors.fg.onEmphasis') : get('colors.
|
24
|
+
})(["position:relative;display:block;padding:", ";margin:", ";overflow:hidden;font-size:", ";color:", ";background-color:", "!important;text-decoration:none;text-overflow:ellipsis;white-space:nowrap;cursor:pointer;border-radius:", ";&:hover{text-decoration:none;background-color:", ";}&:active{color:", ";background-color:", ";}.count{float:right;font-weight:", ";}", ";", ";"], props => props.small ? `${get('space.1')(props)} 10px` : `${get('space.2')(props)} 11px`, props => props.small ? '0 0 2px' : '0 0 5px 0', get('fontSizes.1'), props => props.selected ? get('colors.fg.onEmphasis') : get('colors.fg.muted'), props => props.selected ? get('colors.accent.emphasis') : '', get('radii.1'), get('colors.canvas.subtle'), get('colors.fg.onEmphasis'), get('colors.accent.emphasis'), get('fontWeights.bold'), COMMON, sx);
|
25
25
|
|
26
26
|
function FilterListItem({
|
27
27
|
children,
|
package/lib-esm/Label.js
CHANGED
@@ -2,7 +2,7 @@ import styled, { css } from 'styled-components';
|
|
2
2
|
import { borderColor, variant } from 'styled-system';
|
3
3
|
import { COMMON, get } from './constants';
|
4
4
|
import sx from './sx';
|
5
|
-
const outlineStyles = css(["margin-top:-1px;margin-bottom:-1px;color:", ";border:", " solid ", ";box-shadow:none;", ";", ";background-color:transparent;"], get('colors.
|
5
|
+
const outlineStyles = css(["margin-top:-1px;margin-bottom:-1px;color:", ";border:", " solid ", ";box-shadow:none;", ";", ";background-color:transparent;"], get('colors.fg.muted'), get('borderWidths.1'), get('colors.border.default'), borderColor, COMMON);
|
6
6
|
const sizeVariant = variant({
|
7
7
|
variants: {
|
8
8
|
small: {
|
package/lib-esm/Link.js
CHANGED
@@ -11,5 +11,5 @@ const hoverColor = system({
|
|
11
11
|
const Link = styled.a.withConfig({
|
12
12
|
displayName: "Link",
|
13
13
|
componentId: "sc-1brdqhf-0"
|
14
|
-
})(["color:", ";text-decoration:", ";&:hover{text-decoration:", ";", ";}&:is(button){display:inline-block;padding:0;font-size:inherit;white-space:nowrap;cursor:pointer;user-select:none;background-color:transparent;border:0;appearance:none;}", ";", ";", ";"], props => props.muted ? get('colors.
|
14
|
+
})(["color:", ";text-decoration:", ";&:hover{text-decoration:", ";", ";}&:is(button){display:inline-block;padding:0;font-size:inherit;white-space:nowrap;cursor:pointer;user-select:none;background-color:transparent;border:0;appearance:none;}", ";", ";", ";"], props => props.muted ? get('colors.fg.muted')(props) : get('colors.accent.fg')(props), props => props.underline ? 'underline' : 'none', props => props.muted ? 'none' : 'underline', props => props.hoverColor ? hoverColor : props.muted ? `color: ${get('colors.accent.fg')(props)}` : '', TYPOGRAPHY, COMMON, sx);
|
15
15
|
export default Link;
|
@@ -9,7 +9,7 @@ import { buildComponentData, buildPaginationModel } from './model';
|
|
9
9
|
const Page = styled.a.withConfig({
|
10
10
|
displayName: "Pagination__Page",
|
11
11
|
componentId: "b80nss-0"
|
12
|
-
})(["display:inline-block;min-width:32px;padding:5px 10px;font-style:normal;line-height:20px;color:", ";text-align:center;white-space:nowrap;vertical-align:middle;cursor:pointer;user-select:none;text-decoration:none;margin-right:", ";&:last-child{margin-right:0;}border:", " solid transparent;border-radius:", ";transition:border-color 0.2s cubic-bezier(0.3,0,0.5,1);&:hover,&:focus{text-decoration:none;border-color:", ";outline:0;transition-duration:0.1s;}&:active{border-color:", ";}&[rel='prev'],&[rel='next']{color:", ";}&[aria-current],&[aria-current]:hover{color:", ";background-color:", ";border-color:transparent;}&[aria-disabled],&[aria-disabled]:hover{color:", ";cursor:default;border-color:transparent;}@supports (clip-path:polygon(50% 0,100% 50%,50% 100%)){&[rel='prev']::before,&[rel='next']::after{display:inline-block;width:16px;height:16px;vertical-align:text-bottom;content:'';background-color:currentColor;}&[rel='prev']::before{margin-right:", ";clip-path:polygon( 9.8px 12.8px,8.7px 12.8px,4.5px 8.5px,4.5px 7.5px,8.7px 3.2px,9.8px 4.3px,6.1px 8px,9.8px 11.7px,9.8px 12.8px );}&[rel='next']::after{margin-left:", ";clip-path:polygon( 6.2px 3.2px,7.3px 3.2px,11.5px 7.5px,11.5px 8.5px,7.3px 12.8px,6.2px 11.7px,9.9px 8px,6.2px 4.3px,6.2px 3.2px );}}", ";"], get('colors.fg.default'), get('space.1'), get('borderWidths.1'), get('radii.2'), get('colors.border.default'), get('colors.border.muted'), get('colors.accent.fg'), get('colors.fg.onEmphasis'), get('colors.accent.emphasis'), get('colors.
|
12
|
+
})(["display:inline-block;min-width:32px;padding:5px 10px;font-style:normal;line-height:20px;color:", ";text-align:center;white-space:nowrap;vertical-align:middle;cursor:pointer;user-select:none;text-decoration:none;margin-right:", ";&:last-child{margin-right:0;}border:", " solid transparent;border-radius:", ";transition:border-color 0.2s cubic-bezier(0.3,0,0.5,1);&:hover,&:focus{text-decoration:none;border-color:", ";outline:0;transition-duration:0.1s;}&:active{border-color:", ";}&[rel='prev'],&[rel='next']{color:", ";}&[aria-current],&[aria-current]:hover{color:", ";background-color:", ";border-color:transparent;}&[aria-disabled],&[aria-disabled]:hover{color:", ";cursor:default;border-color:transparent;}@supports (clip-path:polygon(50% 0,100% 50%,50% 100%)){&[rel='prev']::before,&[rel='next']::after{display:inline-block;width:16px;height:16px;vertical-align:text-bottom;content:'';background-color:currentColor;}&[rel='prev']::before{margin-right:", ";clip-path:polygon( 9.8px 12.8px,8.7px 12.8px,4.5px 8.5px,4.5px 7.5px,8.7px 3.2px,9.8px 4.3px,6.1px 8px,9.8px 11.7px,9.8px 12.8px );}&[rel='next']::after{margin-left:", ";clip-path:polygon( 6.2px 3.2px,7.3px 3.2px,11.5px 7.5px,11.5px 8.5px,7.3px 12.8px,6.2px 11.7px,9.9px 8px,6.2px 4.3px,6.2px 3.2px );}}", ";"], get('colors.fg.default'), get('space.1'), get('borderWidths.1'), get('radii.2'), get('colors.border.default'), get('colors.border.muted'), get('colors.accent.fg'), get('colors.fg.onEmphasis'), get('colors.accent.emphasis'), get('colors.fg.muted'), get('space.1'), get('space.1'), COMMON);
|
13
13
|
|
14
14
|
function usePaginationPages({
|
15
15
|
theme,
|
@@ -1,7 +1,7 @@
|
|
1
1
|
import styled, { css } from 'styled-components';
|
2
2
|
import { COMMON, get } from '../constants';
|
3
3
|
import sx from '../sx';
|
4
|
-
const dividerStyles = css(["padding:", " ", ";margin:0;font-size:", ";font-weight:", ";color:", ";background-color:", ";border-bottom:", " solid ", ";"], get('space.1'), get('space.3'), get('fontSizes.0'), get('fontWeights.bold'), get('colors.
|
4
|
+
const dividerStyles = css(["padding:", " ", ";margin:0;font-size:", ";font-weight:", ";color:", ";background-color:", ";border-bottom:", " solid ", ";"], get('space.1'), get('space.3'), get('fontSizes.0'), get('fontWeights.bold'), get('colors.fg.muted'), get('colors.canvas.subtle'), get('borderWidths.1'), get('colors.border.muted'));
|
5
5
|
const SelectMenuDivider = styled.div.withConfig({
|
6
6
|
displayName: "SelectMenuDivider",
|
7
7
|
componentId: "sc-2p0bwt-0"
|
@@ -1,7 +1,7 @@
|
|
1
1
|
import styled, { css } from 'styled-components';
|
2
2
|
import { COMMON, get } from '../constants';
|
3
3
|
import sx from '../sx';
|
4
|
-
const footerStyles = css(["margin-top:-1px;padding:", " ", ";font-size:", ";color:", ";text-align:center;border-top:", " solid ", ";@media (min-width:", "){padding:", " ", ";}"], get('space.2'), get('space.3'), get('fontSizes.0'), get('colors.
|
4
|
+
const footerStyles = css(["margin-top:-1px;padding:", " ", ";font-size:", ";color:", ";text-align:center;border-top:", " solid ", ";@media (min-width:", "){padding:", " ", ";}"], get('space.2'), get('space.3'), get('fontSizes.0'), get('colors.fg.muted'), get('borderWidths.1'), get('colors.border.muted'), get('breakpoints.0'), get('space.1'), get('space.2'));
|
5
5
|
const SelectMenuFooter = styled.footer.withConfig({
|
6
6
|
displayName: "SelectMenuFooter",
|
7
7
|
componentId: "rkvco1-0"
|
@@ -7,7 +7,7 @@ import { COMMON, get } from '../constants';
|
|
7
7
|
import StyledOcticon from '../StyledOcticon';
|
8
8
|
import sx from '../sx';
|
9
9
|
import { MenuContext } from './SelectMenuContext';
|
10
|
-
export const listItemStyles = css(["display:flex;align-items:center;padding:", ";overflow:hidden;text-align:left;cursor:pointer;background-color:", ";border:0;border-bottom:", " solid ", ";color:", ";text-decoration:none;font-size:", ";font-family:inherit;width:100%;&:hover{text-decoration:none;}&:focus{outline:none;}&[hidden]{display:none !important;}@media (min-width:", "){padding-top:", ";padding-bottom:", ";}.SelectMenu-icon{width:", ";margin-right:", ";flex-shrink:0;}.SelectMenu-selected-icon{visibility:hidden;transition:transform 0.12s cubic-bezier(0.5,0.1,1,0.5),visibility 0s 0.12s linear;transform:scale(0);}&[aria-checked='true']{font-weight:500;color:", ";.SelectMenu-selected-icon{visibility:visible;transition:transform 0.12s cubic-bezier(0,0,0.2,1),visibility 0s linear;transform:scale(1);}}@media (hover:hover){&:hover,&:active,&:focus{background-color:", ";}}@media (hover:none){&:focus,&:active{background-color:", ";}-webkit-tap-highlight-color:", ";}"], get('space.3'), get('colors.canvas.overlay'), get('borderWidths.1'), get('colors.border.muted'), get('colors.
|
10
|
+
export const listItemStyles = css(["display:flex;align-items:center;padding:", ";overflow:hidden;text-align:left;cursor:pointer;background-color:", ";border:0;border-bottom:", " solid ", ";color:", ";text-decoration:none;font-size:", ";font-family:inherit;width:100%;&:hover{text-decoration:none;}&:focus{outline:none;}&[hidden]{display:none !important;}@media (min-width:", "){padding-top:", ";padding-bottom:", ";}.SelectMenu-icon{width:", ";margin-right:", ";flex-shrink:0;}.SelectMenu-selected-icon{visibility:hidden;transition:transform 0.12s cubic-bezier(0.5,0.1,1,0.5),visibility 0s 0.12s linear;transform:scale(0);}&[aria-checked='true']{font-weight:500;color:", ";.SelectMenu-selected-icon{visibility:visible;transition:transform 0.12s cubic-bezier(0,0,0.2,1),visibility 0s linear;transform:scale(1);}}@media (hover:hover){&:hover,&:active,&:focus{background-color:", ";}}@media (hover:none){&:focus,&:active{background-color:", ";}-webkit-tap-highlight-color:", ";}"], get('space.3'), get('colors.canvas.overlay'), get('borderWidths.1'), get('colors.border.muted'), get('colors.fg.muted'), get('fontSizes.0'), get('breakpoints.0'), get('space.2'), get('space.2'), get('space.3'), get('space.2'), get('colors.fg.default'), get('colors.neutral.subtle'), get('colors.canvas.subtle'), get('colors.selectMenu.tapHighlight'));
|
11
11
|
const StyledItem = styled.a.attrs(() => ({
|
12
12
|
role: 'menuitemcheckbox'
|
13
13
|
})).withConfig({
|
@@ -6,7 +6,7 @@ import styled, { css } from 'styled-components';
|
|
6
6
|
import { COMMON, get } from '../constants';
|
7
7
|
import sx from '../sx';
|
8
8
|
import { MenuContext } from './SelectMenuContext';
|
9
|
-
const tabStyles = css(["flex:1;padding:", " ", ";font-size:", ";font-weight:500;color:", ";text-align:center;background-color:transparent;border:0;box-shadow:inset 0 -1px 0 ", ";@media (min-width:", "){flex:none;padding:", " ", ";border:", " solid transparent;border-bottom-width:0;border-top-left-radius:", ";border-top-right-radius:", ";}&[aria-selected='true']{z-index:1;color:", ";background-color:", ";box-shadow:0 0 0 1px ", ";@media (min-width:", "){border-color:", ";box-shadow:none;}}&:focus{background-color:", ";}"], get('space.2'), get('space.3'), get('fontSizes.0'), get('colors.
|
9
|
+
const tabStyles = css(["flex:1;padding:", " ", ";font-size:", ";font-weight:500;color:", ";text-align:center;background-color:transparent;border:0;box-shadow:inset 0 -1px 0 ", ";@media (min-width:", "){flex:none;padding:", " ", ";border:", " solid transparent;border-bottom-width:0;border-top-left-radius:", ";border-top-right-radius:", ";}&[aria-selected='true']{z-index:1;color:", ";background-color:", ";box-shadow:0 0 0 1px ", ";@media (min-width:", "){border-color:", ";box-shadow:none;}}&:focus{background-color:", ";}"], get('space.2'), get('space.3'), get('fontSizes.0'), get('colors.fg.muted'), get('colors.border.muted'), get('breakpoints.0'), get('space.1'), get('space.3'), get('borderWidths.1'), get('radii.2'), get('radii.2'), get('colors.text-primary'), get('colors.canvas.overlay'), get('colors.border.muted'), get('breakpoints.0'), get('colors.border.muted'), get('colors.neutral.subtle'));
|
10
10
|
const StyledTab = styled.button.withConfig({
|
11
11
|
displayName: "SelectMenuTab__StyledTab",
|
12
12
|
componentId: "ga32sz-0"
|
package/lib-esm/SubNav.js
CHANGED
@@ -47,7 +47,7 @@ const SubNavLink = styled.a.attrs(props => ({
|
|
47
47
|
})).withConfig({
|
48
48
|
displayName: "SubNav__SubNavLink",
|
49
49
|
componentId: "f7w0xa-1"
|
50
|
-
})(["padding-left:", ";padding-right:", ";font-weight:", ";font-size:", ";line-height:20px;min-height:34px;color:", ";text-align:center;text-decoration:none;border-top:1px solid ", ";border-bottom:1px solid ", ";border-right:1px solid ", ";display:flex;align-items:center;&:first-of-type{border-top-left-radius:", ";border-bottom-left-radius:", ";border-left:1px solid ", ";}&:last-of-type{border-top-right-radius:", ";border-bottom-right-radius:", ";}&:hover,&:focus{text-decoration:none;background-color:", ";transition:0.2s ease;.SubNav-octicon{color:", ";}}&.selected{color:", ";background-color:", ";border-color:", ";.SubNav-octicon{color:", ";}}", ";", ";"], get('space.3'), get('space.3'), get('fontWeights.semibold'), get('fontSizes.1'), get('colors.fg.default'), get('colors.border.default'), get('colors.border.default'), get('colors.border.default'), get('radii.2'), get('radii.2'), get('colors.border.default'), get('radii.2'), get('radii.2'), get('colors.canvas.subtle'), get('colors.
|
50
|
+
})(["padding-left:", ";padding-right:", ";font-weight:", ";font-size:", ";line-height:20px;min-height:34px;color:", ";text-align:center;text-decoration:none;border-top:1px solid ", ";border-bottom:1px solid ", ";border-right:1px solid ", ";display:flex;align-items:center;&:first-of-type{border-top-left-radius:", ";border-bottom-left-radius:", ";border-left:1px solid ", ";}&:last-of-type{border-top-right-radius:", ";border-bottom-right-radius:", ";}&:hover,&:focus{text-decoration:none;background-color:", ";transition:0.2s ease;.SubNav-octicon{color:", ";}}&.selected{color:", ";background-color:", ";border-color:", ";.SubNav-octicon{color:", ";}}", ";", ";"], get('space.3'), get('space.3'), get('fontWeights.semibold'), get('fontSizes.1'), get('colors.fg.default'), get('colors.border.default'), get('colors.border.default'), get('colors.border.default'), get('radii.2'), get('radii.2'), get('colors.border.default'), get('radii.2'), get('radii.2'), get('colors.canvas.subtle'), get('colors.fg.muted'), get('colors.fg.onEmphasis'), get('colors.accent.emphasis'), get('colors.accent.emphasis'), get('colors.fg.onEmphasis'), COMMON, sx);
|
51
51
|
SubNavLink.displayName = 'SubNav.Link';
|
52
52
|
SubNavLinks.displayName = 'SubNav.Links';
|
53
53
|
export default Object.assign(SubNav, {
|
package/lib-esm/Timeline.js
CHANGED
@@ -15,7 +15,7 @@ const TimelineItem = styled(Box).attrs(props => ({
|
|
15
15
|
})).withConfig({
|
16
16
|
displayName: "Timeline__TimelineItem",
|
17
17
|
componentId: "c4dq2e-1"
|
18
|
-
})(["display:flex;position:relative;padding:", " 0;margin-left:", ";&::before{position:absolute;top:0;bottom:0;left:0;display:block;width:2px;content:'';background-color:", ";}", " ", ";", ";"], get('space.3'), get('space.3'), get('colors.border.muted'), props => props.condensed && css(["padding-top:", ";padding-bottom:0;&:last-child{padding-bottom:", ";}.TimelineItem-Badge{height:16px;margin-top:", ";margin-bottom:", ";color:", ";background-color:", ";border:0;}"], get('space.1'), get('space.3'), get('space.2'), get('space.2'), get('colors.
|
18
|
+
})(["display:flex;position:relative;padding:", " 0;margin-left:", ";&::before{position:absolute;top:0;bottom:0;left:0;display:block;width:2px;content:'';background-color:", ";}", " ", ";", ";"], get('space.3'), get('space.3'), get('colors.border.muted'), props => props.condensed && css(["padding-top:", ";padding-bottom:0;&:last-child{padding-bottom:", ";}.TimelineItem-Badge{height:16px;margin-top:", ";margin-bottom:", ";color:", ";background-color:", ";border:0;}"], get('space.1'), get('space.3'), get('space.2'), get('space.2'), get('colors.fg.muted'), get('colors.canvas.default')), COMMON, sx);
|
19
19
|
|
20
20
|
const TimelineBadge = props => {
|
21
21
|
return /*#__PURE__*/React.createElement(Box, {
|
@@ -45,7 +45,7 @@ TimelineBadge.displayName = "TimelineBadge";
|
|
45
45
|
const TimelineBody = styled(Box).withConfig({
|
46
46
|
displayName: "Timeline__TimelineBody",
|
47
47
|
componentId: "c4dq2e-2"
|
48
|
-
})(["min-width:0;max-width:100%;margin-top:", ";color:", ";flex:auto;font-size:", ";", ";"], get('space.1'), get('colors.
|
48
|
+
})(["min-width:0;max-width:100%;margin-top:", ";color:", ";flex:auto;font-size:", ";", ";"], get('space.1'), get('colors.fg.muted'), get('fontSizes.1'), sx);
|
49
49
|
const TimelineBreak = styled(Box).withConfig({
|
50
50
|
displayName: "Timeline__TimelineBreak",
|
51
51
|
componentId: "c4dq2e-3"
|
package/lib-esm/Token/Token.js
CHANGED
@@ -11,7 +11,7 @@ const tokenBorderWidthPx = 1;
|
|
11
11
|
const DefaultTokenStyled = styled(TokenBase).withConfig({
|
12
12
|
displayName: "Token__DefaultTokenStyled",
|
13
13
|
componentId: "sc-1dg52pw-0"
|
14
|
-
})(["background-color:", ";border-color:", ";border-style:solid;border-width:", "px;color:", ";max-width:100%;padding-right:", ";position:relative;", " ", ""], get('colors.neutral.subtle'), props => props.isSelected ? get('colors.fg.default') : get('colors.border.subtle'), tokenBorderWidthPx, props => props.isSelected ? get('colors.fg.default') : get('colors.
|
14
|
+
})(["background-color:", ";border-color:", ";border-style:solid;border-width:", "px;color:", ";max-width:100%;padding-right:", ";position:relative;", " ", ""], get('colors.neutral.subtle'), props => props.isSelected ? get('colors.fg.default') : get('colors.border.subtle'), tokenBorderWidthPx, props => props.isSelected ? get('colors.fg.default') : get('colors.fg.muted'), props => !props.hideRemoveButton ? 0 : undefined, sx, props => {
|
15
15
|
if (props.isTokenInteractive) {
|
16
16
|
return css(["&:hover{background-color:", ";box-shadow:", ";color:", ";}"], get('colors.neutral.muted'), get('colors.shadow.medium'), get('colors.fg.default'));
|
17
17
|
}
|
package/lib-esm/UnderlineNav.js
CHANGED
@@ -42,7 +42,7 @@ const UnderlineNavLink = styled.a.attrs(props => ({
|
|
42
42
|
})).withConfig({
|
43
43
|
displayName: "UnderlineNav__UnderlineNavLink",
|
44
44
|
componentId: "zrnxqt-1"
|
45
|
-
})(["padding:", " ", ";margin-right:", ";font-size:", ";line-height:", ";color:", ";text-align:center;border-bottom:2px solid transparent;text-decoration:none;&:hover,&:focus{color:", ";text-decoration:none;border-bottom-color:", ";transition:0.2s ease;.UnderlineNav-octicon{color:", ";}}&.selected{color:", ";border-bottom-color:", ";.UnderlineNav-octicon{color:", ";}}", ";", ";"], get('space.3'), get('space.2'), get('space.3'), get('fontSizes.1'), get('lineHeights.default'), get('colors.fg.default'), get('colors.fg.default'), get('colors.neutral.muted'), get('colors.
|
45
|
+
})(["padding:", " ", ";margin-right:", ";font-size:", ";line-height:", ";color:", ";text-align:center;border-bottom:2px solid transparent;text-decoration:none;&:hover,&:focus{color:", ";text-decoration:none;border-bottom-color:", ";transition:0.2s ease;.UnderlineNav-octicon{color:", ";}}&.selected{color:", ";border-bottom-color:", ";.UnderlineNav-octicon{color:", ";}}", ";", ";"], get('space.3'), get('space.2'), get('space.3'), get('fontSizes.1'), get('lineHeights.default'), get('colors.fg.default'), get('colors.fg.default'), get('colors.neutral.muted'), get('colors.fg.muted'), get('colors.fg.default'), get('colors.primer.border.active'), get('colors.fg.default'), COMMON, sx);
|
46
46
|
UnderlineNavLink.displayName = 'UnderlineNav.Link';
|
47
47
|
export default Object.assign(UnderlineNav, {
|
48
48
|
Link: UnderlineNavLink
|
@@ -27,5 +27,5 @@ const TextInputWrapper = styled.span.withConfig({
|
|
27
27
|
} else {
|
28
28
|
return css(["padding:6px 12px;"]);
|
29
29
|
}
|
30
|
-
}, get('colors.
|
30
|
+
}, get('colors.fg.muted'), get('space.2'), get('colors.accent.emphasis'), get('shadows.primer.shadow.focus'), props => props.contrast && css(["background-color:", ";"], get('colors.canvas.inset')), props => props.disabled && css(["color:", ";background-color:", ";border-color:", ";"], get('colors.fg.muted'), get('colors.input.disabledBg'), get('colors.border.default')), props => props.block && css(["display:block;width:100%;"]), get('breakpoints.1'), get('fontSizes.1'), width, minWidth, maxWidth, sizeVariants, sx);
|
31
31
|
export default TextInputWrapper;
|