@primer/components 0.0.0-2021103224924 → 0.0.0-202110322537

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 CHANGED
@@ -1,10 +1,10 @@
1
1
  # @primer/components
2
2
 
3
- ## 0.0.0-2021103224924
3
+ ## 0.0.0-202110322537
4
4
 
5
5
  ### Major Changes
6
6
 
7
- - [#1579](https://github.com/primer/react/pull/1579) [`cf510f78`](https://github.com/primer/react/commit/cf510f78124b818de13130f31d86c74367314445) Thanks [@jfuchs](https://github.com/jfuchs)! - UnderlineNav no longer accepts styled-system props. Please use the `sx` prop to extend Primer component styling instead. See also https://primer.style/react/overriding-styles for information about `sx` and https://primer.style/react/system-props for context on the removal.
7
+ - [#1469](https://github.com/primer/react/pull/1469) [`e1e1e7f7`](https://github.com/primer/react/commit/e1e1e7f7536d6ccd761d9a74f50116cf6c14ad3e) Thanks [@jfuchs](https://github.com/jfuchs)! - Breadcrumbs no longer accepts styled-system props. Please use the `sx` prop to extend Primer component styling instead. See also https://primer.style/react/overriding-styles for information about `sx` and https://primer.style/react/system-props for context on the removal.
8
8
 
9
9
  ### Minor Changes
10
10
 
@@ -810,10 +810,8 @@ import e,{useState as t,useRef as r,useCallback as o,useEffect as a,useMemo as n
810
810
  `,Sn=f.nav`
811
811
  display: flex;
812
812
  justify-content: space-between;
813
- ${It};
814
- ${Mt};
815
813
  ${rr};
816
- `;function En({className:t,children:r,theme:o,...a}){const n=e.Children.map(r,(t=>e.createElement(Tn,{theme:o},t)));return e.createElement(Sn,Pt({className:t,"aria-label":"Breadcrumbs",theme:o},a),e.createElement(or,{as:"ol",my:0,pl:0},n))}En.displayName="Breadcrumbs";const Cn=f.a.attrs((e=>({activeClassName:"string"==typeof e.to?"selected":"",className:en(e.selected&&"selected",e.className),"aria-current":e.selected?"page":null})))`
814
+ `;function En({className:t,children:r,sx:o}){const a=e.Children.map(r,(t=>e.createElement(Tn,null,t)));return e.createElement(Sn,{className:t,"aria-label":"Breadcrumbs",sx:o},e.createElement(or,{as:"ol",my:0,pl:0},a))}En.displayName="Breadcrumbs";const Cn=f.a.attrs((e=>({activeClassName:"string"==typeof e.to?"selected":"",className:en(e.selected&&"selected",e.className),"aria-current":e.selected?"page":null})))`
817
815
  color: ${Nt("colors.accent.fg")};
818
816
  display: inline-block;
819
817
  font-size: ${Nt("fontSizes.1")};
@@ -825,7 +823,6 @@ import e,{useState as t,useRef as r,useCallback as o,useEffect as a,useMemo as n
825
823
  color: ${Nt("colors.fg.default")};
826
824
  pointer-events: none;
827
825
  }
828
- ${It}
829
826
  ${rr};
830
827
  `;En.displayName="Breadcrumbs",Cn.displayName="Breadcrumbs.Item";var zn=Object.assign(En,{Item:Cn});const Nn=Object.assign(En,{Item:Cn}),In={top:"Bottom",right:"Left",bottom:"Top",left:"Right"},An={top:"Left",right:"Top",bottom:"Left",left:"Top"};function Rn(e,t,r){const o=In[e].toLowerCase(),a=An[e].toLowerCase();return{[o]:"100%",[t||a]:t?r:"50%"}}const Ln=Tt({prop:"bg",key:"colors"}),On=Tt({prop:"borderColor",key:"colors"}),Mn=Tt({prop:"borderWidth",key:"borderWidths",scale:[0,1]});function Pn(t){var r;const o=e.useContext(b),a={...t,theme:null!==(r=t.theme)&&void 0!==r?r:o},{bg:n}=Ln(a),{borderColor:i}=On(a),{borderWidth:l}=Mn(a),{size:d=8,location:s="bottom"}=t,[c,f]=function(e){const[t,r]=e.split("-");return[t,r]}(s),g=An[c],u=[-d,0],p=[0,d],m=[d,0],h=`M${u}L${p}L${m}L${u}Z`,v=`M${u}L${p}L${m}`,x={top:`translate(${[d,2*d]}) rotate(180)`,right:`translate(${[0,d]}) rotate(-90)`,bottom:`translate(${[d,0]})`,left:`translate(${[2*d,d]}) rotate(90)`}[c];return e.createElement("svg",{width:2*d,height:2*d,style:{pointerEvents:"none",position:"absolute",...Rn(c,f,d),[`margin${g}`]:f?null:-d}},e.createElement("g",{transform:x},e.createElement("path",{d:h,fill:n}),e.createElement("path",{d:v,fill:"none",stroke:i,strokeWidth:l})))}Pn.displayName="Caret",Pn.locations=["top","top-left","top-right","right","right-top","right-bottom","bottom","bottom-left","bottom-right","left","left-top","left-bottom"],Pn.defaultProps={bg:"canvas.default",borderColor:"border.default",borderWidth:1};const Hn={small:56,medium:96,large:128},Dn=f.div`
831
828
  display: ${e=>e.inline?"inline-flex":"flex"};
@@ -2217,6 +2214,7 @@ import e,{useState as t,useRef as r,useCallback as o,useEffect as a,useMemo as n
2217
2214
  align-self: center;
2218
2215
  }
2219
2216
 
2217
+ ${It};
2220
2218
  ${rr};
2221
2219
  `;function fs({actions:t,className:r,align:o,children:a,full:n,label:i,theme:l,...d}){const s=en(r,"UnderlineNav",o&&`UnderlineNav--${o}`,n&&"UnderlineNav--full");return e.createElement(cs,Pt({className:s,"aria-label":i,theme:l},d),e.createElement("div",{className:"UnderlineNav-body"},a),t&&e.createElement("div",{className:"UnderlineNav-actions"},t))}fs.displayName="UnderlineNav";const gs=f.a.attrs((e=>({activeClassName:"string"==typeof e.to?"selected":"",className:en("UnderlineNav-item",e.selected&&"selected",e.className)})))`
2222
2220
  padding: ${Nt("space.3")} ${Nt("space.2")};
@@ -2249,6 +2247,7 @@ import e,{useState as t,useRef as r,useCallback as o,useEffect as a,useMemo as n
2249
2247
  }
2250
2248
  }
2251
2249
 
2250
+ ${It};
2252
2251
  ${rr};
2253
2252
  `;gs.displayName="UnderlineNav.Link";var us=Object.assign(fs,{Link:gs});export{gr as Absolute,Wa as ActionList,Ya as ActionMenu,bn as Autocomplete,hn as Avatar,yn as AvatarPair,$n as AvatarStack,ls as AvatarToken,Wt as BaseStyles,nr as BorderBox,or as Box,kn as BranchName,Nn as Breadcrumb,zn as Breadcrumbs,qr as Button,mo as ButtonClose,Xr as ButtonDanger,Jr as ButtonGroup,eo as ButtonInvisible,Zr as ButtonOutline,Qr as ButtonPrimary,to as ButtonTableList,Pn as Caret,Fn as CircleBadge,_n as CircleOcticon,ba as ConfirmationDialog,jn as CounterLabel,Gn as Details,ti as Dialog,si as Dropdown,ci as DropdownButton,fi as DropdownMenu,hi as FilterList,gi as FilteredSearch,ur as Fixed,yi as Flash,lr as Flex,$i as FormGroup,sr as Grid,Ei as Header,zi as Heading,as as IssueLabelToken,Li as Label,Ni as LabelGroup,Mi as Link,Ga as Overlay,Pi as Pagehead,Fi as Pagination,Ui as PointerBox,Ki as Popover,fr as Position,Ji as ProgressBar,pr as Relative,_o as SSRProvider,Kl as SelectMenu,Ql as SideNav,$l as Spinner,ad as StateLabel,br as Sticky,Lo as StyledOcticon,sd as SubNav,pd as TabNav,qn as Text,nn as TextInput,Od as TextInputWithTokens,tr as ThemeProvider,Fd as Timeline,Id as Token,ss as Tooltip,Ba as Truncate,us as UnderlineNav,x as theme,Nt as themeGet,Qt as useColorSchemeVar,ma as useConfirm,mr as useDetails,Cr as useOnEscapePress,wr as useOnOutsideClick,Tr as useOpenAndCloseFocus,Nr as useOverlay,Uo as useSSRSafeId,hr as useSafeTimeout,Zt as useTheme};
2254
2253
  //# sourceMappingURL=browser.esm.js.map