Socket
Socket
Sign inDemoInstall

@arch-ui/navbar

Package Overview
Dependencies
97
Maintainers
9
Versions
25
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

Comparing version 0.1.12 to 0.1.13

74

CHANGELOG.md
# @arch-ui/navbar
## 0.1.13
### Patch Changes
- [`04bf1e4bb`](https://github.com/keystonejs/keystone-5/commit/04bf1e4bb0223f4e2e06664bbc9e95c51118eb84) [#2](https://github.com/keystonejs/keystone-5/pull/2) Thanks [@bladey](https://github.com/bladey)! - Updated repository URL in package.json.
- Updated dependencies [[`04bf1e4bb`](https://github.com/keystonejs/keystone-5/commit/04bf1e4bb0223f4e2e06664bbc9e95c51118eb84)]:
- @arch-ui/color-utils@0.0.3
- @arch-ui/theme@0.0.12
## 0.1.12

@@ -7,9 +17,9 @@

- [`5935b89f8`](https://github.com/keystonejs/keystone/commit/5935b89f8862b36f14d09da68f056f759a860f3e) [#3477](https://github.com/keystonejs/keystone/pull/3477) Thanks [@Noviny](https://github.com/Noviny)! - Updating dependencies:
- [`5935b89f8`](https://github.com/keystonejs/keystone-5/commit/5935b89f8862b36f14d09da68f056f759a860f3e) [#3477](https://github.com/keystonejs/keystone-5/pull/3477) Thanks [@Noviny](https://github.com/Noviny)! - Updating dependencies:
These changes bring the keystone dev experience inline with installing keystone from npm :D
* [`0fc878fa9`](https://github.com/keystonejs/keystone/commit/0fc878fa918c3196196f943f195ffaa62fce504b) [#3439](https://github.com/keystonejs/keystone/pull/3439) Thanks [@renovate](https://github.com/apps/renovate)! - Updated babel dependencies.
* [`0fc878fa9`](https://github.com/keystonejs/keystone-5/commit/0fc878fa918c3196196f943f195ffaa62fce504b) [#3439](https://github.com/keystonejs/keystone-5/pull/3439) Thanks [@renovate](https://github.com/apps/renovate)! - Updated babel dependencies.
* Updated dependencies [[`0fc878fa9`](https://github.com/keystonejs/keystone/commit/0fc878fa918c3196196f943f195ffaa62fce504b)]:
* Updated dependencies [[`0fc878fa9`](https://github.com/keystonejs/keystone-5/commit/0fc878fa918c3196196f943f195ffaa62fce504b)]:
- @arch-ui/theme@0.0.11

@@ -21,3 +31,3 @@

- [`2b0f6441`](https://github.com/keystonejs/keystone/commit/2b0f6441e50787a4a82f417b573078717b39e9be) [#2946](https://github.com/keystonejs/keystone/pull/2946) Thanks [@Vultraz](https://github.com/Vultraz)! - Updated react-router-dom to 5.2.0.
- [`2b0f6441`](https://github.com/keystonejs/keystone-5/commit/2b0f6441e50787a4a82f417b573078717b39e9be) [#2946](https://github.com/keystonejs/keystone-5/pull/2946) Thanks [@Vultraz](https://github.com/Vultraz)! - Updated react-router-dom to 5.2.0.

@@ -28,3 +38,3 @@ ## 0.1.10

- [`95babf5d`](https://github.com/keystonejs/keystone/commit/95babf5da8488f2d7f8ab9f91ff640576462af6d) [#2798](https://github.com/keystonejs/keystone/pull/2798) Thanks [@Vultraz](https://github.com/Vultraz)! - Revamped sidebar design.
- [`95babf5d`](https://github.com/keystonejs/keystone-5/commit/95babf5da8488f2d7f8ab9f91ff640576462af6d) [#2798](https://github.com/keystonejs/keystone-5/pull/2798) Thanks [@Vultraz](https://github.com/Vultraz)! - Revamped sidebar design.

@@ -35,3 +45,3 @@ ## 0.1.9

- [`577b5e69`](https://github.com/keystonejs/keystone/commit/577b5e69ac4f949d1be2a80d8f391cb0a4b1333a) [#2799](https://github.com/keystonejs/keystone/pull/2799) Thanks [@MadeByMike](https://github.com/MadeByMike)! - Upgraded React and Emotion packages.
- [`577b5e69`](https://github.com/keystonejs/keystone-5/commit/577b5e69ac4f949d1be2a80d8f391cb0a4b1333a) [#2799](https://github.com/keystonejs/keystone-5/pull/2799) Thanks [@MadeByMike](https://github.com/MadeByMike)! - Upgraded React and Emotion packages.

@@ -42,3 +52,3 @@ ## 0.1.8

- Updated dependencies [[`0de5f232`](https://github.com/keystonejs/keystone/commit/0de5f2321ef8f9fe6dd247c3201372a4156e61e9)]:
- Updated dependencies [[`0de5f232`](https://github.com/keystonejs/keystone-5/commit/0de5f2321ef8f9fe6dd247c3201372a4156e61e9)]:
- @arch-ui/theme@0.0.10

@@ -50,7 +60,7 @@

- [`6b353eff`](https://github.com/keystonejs/keystone/commit/6b353effc8b617137a3978b2c845e01403889722) Thanks [@timleslie](https://github.com/timleslie)! - Upgraded React to 16.13.0.
- [`6b353eff`](https://github.com/keystonejs/keystone-5/commit/6b353effc8b617137a3978b2c845e01403889722) Thanks [@timleslie](https://github.com/timleslie)! - Upgraded React to 16.13.0.
* [`5ba330b8`](https://github.com/keystonejs/keystone/commit/5ba330b8b2609ea0033a636daf9a215a5a192c20) [#2487](https://github.com/keystonejs/keystone/pull/2487) Thanks [@Noviny](https://github.com/Noviny)! - Small changes to package.json (mostly adding a repository field)
* [`5ba330b8`](https://github.com/keystonejs/keystone-5/commit/5ba330b8b2609ea0033a636daf9a215a5a192c20) [#2487](https://github.com/keystonejs/keystone-5/pull/2487) Thanks [@Noviny](https://github.com/Noviny)! - Small changes to package.json (mostly adding a repository field)
* Updated dependencies [[`5ba330b8`](https://github.com/keystonejs/keystone/commit/5ba330b8b2609ea0033a636daf9a215a5a192c20)]:
* Updated dependencies [[`5ba330b8`](https://github.com/keystonejs/keystone-5/commit/5ba330b8b2609ea0033a636daf9a215a5a192c20)]:
- @arch-ui/color-utils@0.0.2

@@ -63,9 +73,9 @@ - @arch-ui/theme@0.0.9

- [`d8a7b8a2`](https://github.com/keystonejs/keystone/commit/d8a7b8a23b4c3e1545d101a92323be165ad362e2) [#2395](https://github.com/keystonejs/keystone/pull/2395) Thanks [@timleslie](https://github.com/timleslie)! - Upgraded all `@emotion.*` dependencies.
- [`d8a7b8a2`](https://github.com/keystonejs/keystone-5/commit/d8a7b8a23b4c3e1545d101a92323be165ad362e2) [#2395](https://github.com/keystonejs/keystone-5/pull/2395) Thanks [@timleslie](https://github.com/timleslie)! - Upgraded all `@emotion.*` dependencies.
* [`aa682b4c`](https://github.com/keystonejs/keystone/commit/aa682b4c4b59f3edb7a87559049f90a06a2f26b5) [#2409](https://github.com/keystonejs/keystone/pull/2409) Thanks [@Vultraz](https://github.com/Vultraz)! - Made active nav item text bold.
* [`aa682b4c`](https://github.com/keystonejs/keystone-5/commit/aa682b4c4b59f3edb7a87559049f90a06a2f26b5) [#2409](https://github.com/keystonejs/keystone-5/pull/2409) Thanks [@Vultraz](https://github.com/Vultraz)! - Made active nav item text bold.
- [`dcdd8ed9`](https://github.com/keystonejs/keystone/commit/dcdd8ed9142cf3328a7af80bc167ef93c7669b09) [#2381](https://github.com/keystonejs/keystone/pull/2381) Thanks [@timleslie](https://github.com/timleslie)! - Updated `@babel/*` dependency packages to latest versions.
- [`dcdd8ed9`](https://github.com/keystonejs/keystone-5/commit/dcdd8ed9142cf3328a7af80bc167ef93c7669b09) [#2381](https://github.com/keystonejs/keystone-5/pull/2381) Thanks [@timleslie](https://github.com/timleslie)! - Updated `@babel/*` dependency packages to latest versions.
- Updated dependencies [[`dcdd8ed9`](https://github.com/keystonejs/keystone/commit/dcdd8ed9142cf3328a7af80bc167ef93c7669b09)]:
- Updated dependencies [[`dcdd8ed9`](https://github.com/keystonejs/keystone-5/commit/dcdd8ed9142cf3328a7af80bc167ef93c7669b09)]:
- @arch-ui/theme@0.0.8

@@ -77,4 +87,4 @@

- [`38f88b62`](https://github.com/keystonejs/keystone/commit/38f88b62d9592d91b56528d4d9c40e9399440c4a) [#2144](https://github.com/keystonejs/keystone/pull/2144) - Upgraded all @babel/\* dependencies.
- Updated dependencies [[`38f88b62`](https://github.com/keystonejs/keystone/commit/38f88b62d9592d91b56528d4d9c40e9399440c4a)]:
- [`38f88b62`](https://github.com/keystonejs/keystone-5/commit/38f88b62d9592d91b56528d4d9c40e9399440c4a) [#2144](https://github.com/keystonejs/keystone-5/pull/2144) - Upgraded all @babel/\* dependencies.
- Updated dependencies [[`38f88b62`](https://github.com/keystonejs/keystone-5/commit/38f88b62d9592d91b56528d4d9c40e9399440c4a)]:
- @arch-ui/theme@0.0.7

@@ -86,4 +96,4 @@

- [`129b0f6`](https://github.com/keystonejs/keystone/commit/129b0f61f34adb7482901d2da4ddb14ce1aedd62) [#2092](https://github.com/keystonejs/keystone/pull/2092) - Upgrade all Babel deps to the same version (7.7.4)
- Updated dependencies [[`129b0f6`](https://github.com/keystonejs/keystone/commit/129b0f61f34adb7482901d2da4ddb14ce1aedd62)]:
- [`129b0f6`](https://github.com/keystonejs/keystone-5/commit/129b0f61f34adb7482901d2da4ddb14ce1aedd62) [#2092](https://github.com/keystonejs/keystone-5/pull/2092) - Upgrade all Babel deps to the same version (7.7.4)
- Updated dependencies [[`129b0f6`](https://github.com/keystonejs/keystone-5/commit/129b0f61f34adb7482901d2da4ddb14ce1aedd62)]:
- @arch-ui/theme@0.0.6

@@ -95,3 +105,3 @@

- [`946a52fd`](https://github.com/keystonejs/keystone/commit/946a52fd7057bb73f4ffd465ef51498172926866) [#1995](https://github.com/keystonejs/keystone/pull/1995) Thanks [@Vultraz](https://github.com/Vultraz)! - Updated `react` and `react-dom` to 16.12.0.
- [`946a52fd`](https://github.com/keystonejs/keystone-5/commit/946a52fd7057bb73f4ffd465ef51498172926866) [#1995](https://github.com/keystonejs/keystone-5/pull/1995) Thanks [@Vultraz](https://github.com/Vultraz)! - Updated `react` and `react-dom` to 16.12.0.

@@ -102,9 +112,9 @@ ## 0.1.2

- [`8226eb47`](https://github.com/keystonejs/keystone/commit/8226eb4709ea8ad5773c900eaaa96068d3cb6bad) [#1819](https://github.com/keystonejs/keystone/pull/1819) Thanks [@w01fgang](https://github.com/w01fgang)! - Upgraded `flow` and fixed flow errors and (probably) bugs.
- [`8226eb47`](https://github.com/keystonejs/keystone-5/commit/8226eb4709ea8ad5773c900eaaa96068d3cb6bad) [#1819](https://github.com/keystonejs/keystone-5/pull/1819) Thanks [@w01fgang](https://github.com/w01fgang)! - Upgraded `flow` and fixed flow errors and (probably) bugs.
* [`8226eb47`](https://github.com/keystonejs/keystone/commit/8226eb4709ea8ad5773c900eaaa96068d3cb6bad) [#1819](https://github.com/keystonejs/keystone/pull/1819) Thanks [@w01fgang](https://github.com/w01fgang)! - Upgraded `@emotion/core` and `@emotion/styled`.
* [`8226eb47`](https://github.com/keystonejs/keystone-5/commit/8226eb4709ea8ad5773c900eaaa96068d3cb6bad) [#1819](https://github.com/keystonejs/keystone-5/pull/1819) Thanks [@w01fgang](https://github.com/w01fgang)! - Upgraded `@emotion/core` and `@emotion/styled`.
- [`d0d84603`](https://github.com/keystonejs/keystone/commit/d0d84603628f64be3c76f6624f163aaaa46a6092) [#1869](https://github.com/keystonejs/keystone/pull/1869) Thanks [@MadeByMike](https://github.com/MadeByMike)! - Made `NavIcons` section easier to click.
- [`d0d84603`](https://github.com/keystonejs/keystone-5/commit/d0d84603628f64be3c76f6624f163aaaa46a6092) [#1869](https://github.com/keystonejs/keystone-5/pull/1869) Thanks [@MadeByMike](https://github.com/MadeByMike)! - Made `NavIcons` section easier to click.
* [`b17b50c0`](https://github.com/keystonejs/keystone/commit/b17b50c0783dd246786aad1de41136967ad73b5c) [#1910](https://github.com/keystonejs/keystone/pull/1910) Thanks [@gautamsi](https://github.com/gautamsi)! - Upgraded `react-router-dom` to v5.1.2 to make use of `useParams` and other hooks provided by `react-router-dom` v5.1.0.
* [`b17b50c0`](https://github.com/keystonejs/keystone-5/commit/b17b50c0783dd246786aad1de41136967ad73b5c) [#1910](https://github.com/keystonejs/keystone-5/pull/1910) Thanks [@gautamsi](https://github.com/gautamsi)! - Upgraded `react-router-dom` to v5.1.2 to make use of `useParams` and other hooks provided by `react-router-dom` v5.1.0.

@@ -115,3 +125,3 @@ ## 0.1.1

- [42c3fbc9](https://github.com/keystonejs/keystone/commit/42c3fbc9): Upgrade emotion to 10.0.14
- [42c3fbc9](https://github.com/keystonejs/keystone-5/commit/42c3fbc9): Upgrade emotion to 10.0.14

@@ -122,3 +132,3 @@ ## 0.1.0

- [c2dc6eb3](https://github.com/keystonejs/keystone/commit/c2dc6eb3):
- [c2dc6eb3](https://github.com/keystonejs/keystone-5/commit/c2dc6eb3):

@@ -131,3 +141,3 @@ Allow changing the underlying element type of the ItemElement component with the `as`

- [19fe6c1b](https://github.com/keystonejs/keystone/commit/19fe6c1b):
- [19fe6c1b](https://github.com/keystonejs/keystone-5/commit/19fe6c1b):

@@ -140,3 +150,3 @@ Move frontmatter in docs into comments

- [d580c298](https://github.com/keystonejs/keystone/commit/d580c298):
- [d580c298](https://github.com/keystonejs/keystone-5/commit/d580c298):

@@ -149,3 +159,3 @@ Minor Admin UI Tweaks

- [81dc0be5](https://github.com/keystonejs/keystone/commit/81dc0be5):
- [81dc0be5](https://github.com/keystonejs/keystone-5/commit/81dc0be5):

@@ -156,3 +166,3 @@ - Update dependencies

- [patch][e75c105c](https://github.com/keystonejs/keystone/commit/e75c105c):
- [patch][e75c105c](https://github.com/keystonejs/keystone-5/commit/e75c105c):

@@ -163,3 +173,3 @@ - admin revamp

- [patch][24bed583](https://github.com/keystonejs/keystone/commit/24bed583):
- [patch][24bed583](https://github.com/keystonejs/keystone-5/commit/24bed583):

@@ -170,3 +180,3 @@ - Update react-router-dom dependency to 5.0.0

- [patch][85cb44a9](https://github.com/keystonejs/keystone/commit/85cb44a9):
- [patch][85cb44a9](https://github.com/keystonejs/keystone-5/commit/85cb44a9):

@@ -177,3 +187,3 @@ - Add PrimaryNavHeading component and change styles

- [patch][7417ea3a](https://github.com/keystonejs/keystone/commit/7417ea3a):
- [patch][7417ea3a](https://github.com/keystonejs/keystone-5/commit/7417ea3a):

@@ -180,0 +190,0 @@ - Update patch-level dependencies

@@ -5,3 +5,3 @@ 'use strict';

var _defineProperty = require('@babel/runtime/helpers/defineProperty');
var _objectSpread = require('@babel/runtime/helpers/objectSpread2');
var styled = require('@emotion/styled');

@@ -16,6 +16,3 @@ var theme = require('@arch-ui/theme');

var _defineProperty__default = /*#__PURE__*/_interopDefault(_defineProperty);
var styled__default = /*#__PURE__*/_interopDefault(styled);
var _extends__default = /*#__PURE__*/_interopDefault(_extends);
var _objectWithoutProperties__default = /*#__PURE__*/_interopDefault(_objectWithoutProperties);
var React__default = /*#__PURE__*/_interopDefault(React);

@@ -29,3 +26,3 @@

} = _ref,
props = _objectWithoutProperties__default['default'](_ref, ["as", "isSelected", "mouseIsOverNav"]);
props = _objectWithoutProperties(_ref, ["as", "isSelected", "mouseIsOverNav"]);

@@ -35,3 +32,3 @@ if (Tag) return /*#__PURE__*/React.createElement(Tag, props);

if (props.href) return /*#__PURE__*/React.createElement("a", props);
return /*#__PURE__*/React.createElement("button", _extends__default['default']({
return /*#__PURE__*/React.createElement("button", _extends({
type: "button"

@@ -41,5 +38,2 @@ }, props));

function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); if (enumerableOnly) symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; }); keys.push.apply(keys, symbols); } return keys; }
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i] != null ? arguments[i] : {}; if (i % 2) { ownKeys(Object(source), true).forEach(function (key) { _defineProperty__default['default'](target, key, source[key]); }); } else if (Object.getOwnPropertyDescriptors) { Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)); } else { ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } } return target; }
const PRIMARY_NAV_GUTTER = theme.gridSize * 2;

@@ -46,0 +40,0 @@ const NavGroupIcons = styled__default['default'].div({

@@ -1,20 +0,30 @@

"use strict";
'use strict';
Object.defineProperty(exports, "__esModule", {
value: !0
});
Object.defineProperty(exports, '__esModule', { value: true });
var _defineProperty = require("@babel/runtime/helpers/defineProperty"), styled = require("@emotion/styled"), theme = require("@arch-ui/theme"), _extends = require("@babel/runtime/helpers/extends"), _objectWithoutProperties = require("@babel/runtime/helpers/objectWithoutProperties"), React = require("react"), reactRouterDom = require("react-router-dom");
var _objectSpread = require('@babel/runtime/helpers/objectSpread2');
var styled = require('@emotion/styled');
var theme = require('@arch-ui/theme');
var _extends = require('@babel/runtime/helpers/extends');
var _objectWithoutProperties = require('@babel/runtime/helpers/objectWithoutProperties');
var React = require('react');
var reactRouterDom = require('react-router-dom');
function _interopDefault(e) {
return e && e.__esModule ? e : {
default: e
};
}
function _interopDefault (e) { return e && e.__esModule ? e : { 'default': e }; }
var _defineProperty__default = _interopDefault(_defineProperty), styled__default = _interopDefault(styled), _extends__default = _interopDefault(_extends), _objectWithoutProperties__default = _interopDefault(_objectWithoutProperties), React__default = _interopDefault(React);
var styled__default = /*#__PURE__*/_interopDefault(styled);
var React__default = /*#__PURE__*/_interopDefault(React);
const ItemElement = _ref => {
let {as: Tag, isSelected: isSelected, mouseIsOverNav: mouseIsOverNav} = _ref, props = _objectWithoutProperties__default.default(_ref, [ "as", "isSelected", "mouseIsOverNav" ]);
return Tag ? React.createElement(Tag, props) : props.to ? React.createElement(reactRouterDom.Link, props) : props.href ? React.createElement("a", props) : React.createElement("button", _extends__default.default({
const ItemElement = (_ref) => {
let {
as: Tag,
isSelected,
mouseIsOverNav
} = _ref,
props = _objectWithoutProperties(_ref, ["as", "isSelected", "mouseIsOverNav"]);
if (Tag) return /*#__PURE__*/React.createElement(Tag, props);
if (props.to) return /*#__PURE__*/React.createElement(reactRouterDom.Link, props);
if (props.href) return /*#__PURE__*/React.createElement("a", props);
return /*#__PURE__*/React.createElement("button", _extends({
type: "button"

@@ -24,41 +34,25 @@ }, props));

function ownKeys(object, enumerableOnly) {
var keys = Object.keys(object);
if (Object.getOwnPropertySymbols) {
var symbols = Object.getOwnPropertySymbols(object);
enumerableOnly && (symbols = symbols.filter((function(sym) {
return Object.getOwnPropertyDescriptor(object, sym).enumerable;
}))), keys.push.apply(keys, symbols);
}
return keys;
}
function _objectSpread(target) {
for (var i = 1; i < arguments.length; i++) {
var source = null != arguments[i] ? arguments[i] : {};
i % 2 ? ownKeys(Object(source), !0).forEach((function(key) {
_defineProperty__default.default(target, key, source[key]);
})) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach((function(key) {
Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key));
}));
}
return target;
}
const PRIMARY_NAV_GUTTER = 2 * theme.gridSize, NavGroupIcons = styled__default.default.div({
alignItems: "center",
alignSelf: "stretch",
display: "flex",
justifyContent: "space-between"
}), PrimaryNav = styled__default.default.nav({
const PRIMARY_NAV_GUTTER = theme.gridSize * 2;
const NavGroupIcons = styled__default['default'].div({
alignItems: 'center',
alignSelf: 'stretch',
display: 'flex',
justifyContent: 'space-between'
});
const PrimaryNav = styled__default['default'].nav({
backgroundColor: theme.colors.page,
boxSizing: "border-box",
display: "flex",
flexDirection: "column",
height: "100vh",
position: "fixed",
boxSizing: 'border-box',
display: 'flex',
flexDirection: 'column',
height: '100vh',
position: 'fixed',
zIndex: 2
}), PrimaryNavScrollArea = styled__default.default.div(({hasScroll: hasScroll, isBottom: isBottom, isScrollable: isScrollable}) => {
});
const PrimaryNavScrollArea = styled__default['default'].div(({
hasScroll,
isBottom,
isScrollable
}) => {
const divider = {
backgroundColor: "rgba(9, 30, 66, 0.1)",
backgroundColor: 'rgba(9, 30, 66, 0.1)',
content: '" "',

@@ -68,20 +62,23 @@ height: 2,

right: PRIMARY_NAV_GUTTER,
position: "absolute"
}, before = hasScroll ? _objectSpread(_objectSpread({}, divider), {}, {
position: 'absolute'
};
const before = hasScroll ? _objectSpread(_objectSpread({}, divider), {}, {
top: 0
}) : null, after = isScrollable && !isBottom ? _objectSpread(_objectSpread({}, divider), {}, {
}) : null;
const after = isScrollable && !isBottom ? _objectSpread(_objectSpread({}, divider), {}, {
bottom: 0
}) : null;
return {
boxSizing: "border-box",
boxSizing: 'border-box',
flex: 1,
overflowY: "auto",
overflowX: "hidden",
overflowY: 'auto',
overflowX: 'hidden',
minWidth: 140,
paddingBottom: PRIMARY_NAV_GUTTER,
width: "100%",
":before": before,
":after": after
width: '100%',
':before': before,
':after': after
};
}), BrandItem = styled__default.default.h2({
});
const BrandItem = styled__default['default'].h2({
fontSize: 18,

@@ -91,6 +88,11 @@ fontWeight: 500,

paddingBottom: PRIMARY_NAV_GUTTER
}), PrimaryNavItem = styled__default.default(ItemElement)(({depth: depth, isSelected: isSelected, mouseIsOverNav: mouseIsOverNav}) => {
});
const PrimaryNavItem = styled__default['default'](ItemElement)(({
depth,
isSelected,
mouseIsOverNav
}) => {
const selectedStyles = isSelected ? {
"&, :hover, :active, :focus": {
":after": {
'&, :hover, :active, :focus': {
':after': {
backgroundColor: theme.colors.primary

@@ -102,83 +104,104 @@ }

border: 0,
borderRight: "1px solid transparent",
borderRight: '1px solid transparent',
color: isSelected ? theme.colors.N90 : mouseIsOverNav ? theme.colors.N70 : theme.colors.N40,
display: "block",
display: 'block',
marginBottom: 2,
overflow: "hidden",
padding: 1.5 * theme.gridSize + "px",
overflow: 'hidden',
padding: `${theme.gridSize * 1.5}px`,
paddingLeft: depth ? PRIMARY_NAV_GUTTER * depth : PRIMARY_NAV_GUTTER,
position: "relative",
textDecoration: "none",
textOverflow: "ellipsis",
whiteSpace: "nowrap",
transition: "color 110ms",
fontWeight: isSelected ? "bold" : "normal",
position: 'relative',
textDecoration: 'none',
textOverflow: 'ellipsis',
whiteSpace: 'nowrap',
transition: 'color 110ms',
fontWeight: isSelected ? 'bold' : 'normal',
flexGrow: 1,
flexBasis: "100%",
":hover, :focus": {
flexBasis: '100%',
':hover, :focus': {
backgroundColor: theme.colors.N10,
textDecoration: "none"
textDecoration: 'none'
},
":active": {
':active': {
backgroundColor: theme.colors.N10
},
":after": {
':after': {
borderRadius: 2,
bottom: 2,
content: '" "',
pointerEvents: "none",
position: "absolute",
pointerEvents: 'none',
position: 'absolute',
right: 6,
top: 2,
transition: "background-color 110ms",
transition: 'background-color 110ms',
width: 4
}
}, selectedStyles);
}), NavIcon = styled__default.default(ItemElement)(({mouseIsOverNav: mouseIsOverNav}) => ({
color: mouseIsOverNav ? theme.colors.N70 : theme.colors.N40,
padding: PRIMARY_NAV_GUTTER,
textDecoration: "none",
flexGrow: 1,
flexBasis: "100%",
display: "flex",
justifyContent: "center",
alignItems: "center",
":hover, :focus": {
backgroundColor: theme.colors.N10,
textDecoration: "none"
},
":active": {
backgroundColor: theme.colors.N10
}
})), PrimaryNavHeading = styled__default.default.h3(({depth: depth}) => ({
});
const NavIcon = styled__default['default'](ItemElement)(({
mouseIsOverNav
}) => {
return {
color: mouseIsOverNav ? theme.colors.N70 : theme.colors.N40,
padding: PRIMARY_NAV_GUTTER,
textDecoration: 'none',
flexGrow: 1,
flexBasis: '100%',
display: 'flex',
justifyContent: 'center',
alignItems: 'center',
':hover, :focus': {
backgroundColor: theme.colors.N10,
textDecoration: 'none'
},
':active': {
backgroundColor: theme.colors.N10
}
};
});
const PrimaryNavHeading = styled__default['default'].h3(({
depth
}) => ({
color: theme.colors.N40,
fontSize: "0.85em",
fontWeight: "bold",
marginTop: "2em",
fontSize: '0.85em',
fontWeight: 'bold',
marginTop: '2em',
paddingLeft: depth ? PRIMARY_NAV_GUTTER * depth : PRIMARY_NAV_GUTTER,
paddingRight: PRIMARY_NAV_GUTTER,
textTransform: "uppercase"
})), Wrapper = styled__default.default.nav({
borderBottom: "1px solid " + theme.colors.N10,
textTransform: 'uppercase'
}));
const Wrapper = styled__default['default'].nav({
borderBottom: `1px solid ${theme.colors.N10}`,
color: theme.colors.text,
fontSize: "0.85em"
}), SecondaryNavItem = styled__default.default(ItemElement)(({isSelected: isSelected}) => ({
fontSize: '0.85em'
});
const SecondaryNavItem = styled__default['default'](ItemElement)(({
isSelected
}) => ({
boxShadow: `inset 0 ${isSelected ? -2 : 0}px 0 currentColor`,
color: isSelected ? theme.colors.text : theme.colors.N60,
cursor: "pointer",
display: "inline-block",
cursor: 'pointer',
display: 'inline-block',
marginRight: theme.gridSize,
paddingBottom: 2 * theme.gridSize,
paddingTop: 2 * theme.gridSize,
transition: "box-shadow 200ms",
":hover": {
paddingBottom: theme.gridSize * 2,
paddingTop: theme.gridSize * 2,
transition: 'box-shadow 200ms',
':hover': {
color: theme.colors.text,
textDecoration: "none"
textDecoration: 'none'
}
})), SecondaryNav = ({children: children}) => React__default.default.createElement(Wrapper, null, children);
}));
const SecondaryNav = ({
children
}) => /*#__PURE__*/React__default['default'].createElement(Wrapper, null, children);
exports.BrandItem = BrandItem, exports.NavGroupIcons = NavGroupIcons, exports.NavIcon = NavIcon,
exports.PRIMARY_NAV_GUTTER = PRIMARY_NAV_GUTTER, exports.PrimaryNav = PrimaryNav,
exports.PrimaryNavHeading = PrimaryNavHeading, exports.PrimaryNavItem = PrimaryNavItem,
exports.PrimaryNavScrollArea = PrimaryNavScrollArea, exports.SecondaryNav = SecondaryNav,
exports.BrandItem = BrandItem;
exports.NavGroupIcons = NavGroupIcons;
exports.NavIcon = NavIcon;
exports.PRIMARY_NAV_GUTTER = PRIMARY_NAV_GUTTER;
exports.PrimaryNav = PrimaryNav;
exports.PrimaryNavHeading = PrimaryNavHeading;
exports.PrimaryNavItem = PrimaryNavItem;
exports.PrimaryNavScrollArea = PrimaryNavScrollArea;
exports.SecondaryNav = SecondaryNav;
exports.SecondaryNavItem = SecondaryNavItem;

@@ -1,2 +0,2 @@

import _defineProperty from '@babel/runtime/helpers/esm/defineProperty';
import _objectSpread from '@babel/runtime/helpers/esm/objectSpread2';
import styled from '@emotion/styled';

@@ -25,5 +25,2 @@ import { gridSize, colors } from '@arch-ui/theme';

function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); if (enumerableOnly) symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; }); keys.push.apply(keys, symbols); } return keys; }
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i] != null ? arguments[i] : {}; if (i % 2) { ownKeys(Object(source), true).forEach(function (key) { _defineProperty(target, key, source[key]); }); } else if (Object.getOwnPropertyDescriptors) { Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)); } else { ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } } return target; }
const PRIMARY_NAV_GUTTER = gridSize * 2;

@@ -30,0 +27,0 @@ const NavGroupIcons = styled.div({

{
"name": "@arch-ui/navbar",
"description": "Navbar UI as used in @keystonejs Admin UI.",
"version": "0.1.12",
"version": "0.1.13",
"author": "Jed Watson",

@@ -9,12 +9,12 @@ "license": "MIT",

"peerDependencies": {
"react": "^16.13.1"
"react": "^17.0.1"
},
"devDependencies": {
"react": "^16.13.1"
"react": "^17.0.1"
},
"dependencies": {
"@arch-ui/color-utils": "^0.0.2",
"@arch-ui/theme": "^0.0.11",
"@babel/runtime": "^7.11.2",
"@emotion/core": "^10.0.35",
"@arch-ui/color-utils": "^0.0.3",
"@arch-ui/theme": "^0.0.12",
"@babel/runtime": "^7.12.13",
"@emotion/core": "^10.1.1",
"@emotion/styled": "^10.0.27",

@@ -24,3 +24,3 @@ "react-router-dom": "5.2.0"

"module": "dist/navbar.esm.js",
"repository": "https://github.com/keystonejs/keystone/tree/master/packages/arch/packages/navbar"
"repository": "https://github.com/keystonejs/keystone-5/tree/master/packages/arch/packages/navbar"
}
SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc