@akinon/ui-layout 0.3.0 → 0.3.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.
@@ -1,9 +1,3 @@
1
- /* TODO normalize cross-browser incosistencies */
2
- body {
3
- padding: 0;
4
- margin: 0;
5
- }
6
-
7
1
  .akinon-layout {
8
2
  &:not(.akinon-layout-has-sider) {
9
3
  border-inline: 1px solid var(--color-gray-900);
@@ -28,7 +22,6 @@ body {
28
22
  height: 100vh;
29
23
  overflow-y: auto;
30
24
 
31
- /* TODO normalize scrollbars. they took up huge space */
32
25
  &.left {
33
26
  inset-inline-start: 0;
34
27
  }
@@ -24,4 +24,6 @@ export type LeftSiderItem = {
24
24
  export { Layout };
25
25
  export * from './Flex';
26
26
  export * from './Grid';
27
+ export * from './nav-card';
28
+ export * from './page-heading';
27
29
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/index.tsx"],"names":[],"mappings":";AAAA,OAAO,aAAa,CAAC;AAErB,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AACpC,OAAO,EAAE,MAAM,EAAE,MAAM,UAAU,CAAC;AAClC,OAAO,EAAE,MAAM,EAAE,MAAM,UAAU,CAAC;AAClC,OAAO,EAAE,MAAM,IAAI,cAAc,EAAE,MAAM,UAAU,CAAC;AACpD,OAAO,EAAE,KAAK,EAAE,MAAM,SAAS,CAAC;AAEhC,KAAK,mBAAmB,GAAG,OAAO,cAAc,GAAG;IACjD,MAAM,EAAE,OAAO,MAAM,CAAC;IACtB,MAAM,EAAE,OAAO,MAAM,CAAC;IACtB,OAAO,EAAE,OAAO,OAAO,CAAC;IACxB,KAAK,EAAE,OAAO,KAAK,CAAC;CACrB,CAAC;AAEF,QAAA,MAAM,MAAM,EAAE,mBAKZ,CAAC;AAGH,MAAM,MAAM,aAAa,GAAG;IAC1B,GAAG,EAAE,MAAM,CAAC;IACZ,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;AAEF,OAAO,EAAE,MAAM,EAAE,CAAC;AAGlB,cAAc,QAAQ,CAAC;AACvB,cAAc,QAAQ,CAAC;AACvB,cAAc,YAAY,CAAC;AAC3B,cAAc,gBAAgB,CAAC"}
package/dist/cjs/index.js CHANGED
@@ -28,5 +28,9 @@ const Layout = Object.assign(Layout_1.Layout, {
28
28
  Sider: Sider_1.Sider
29
29
  });
30
30
  exports.Layout = Layout;
31
+ // TODO: Rename these files to be lowercase.
32
+ // TODO: Add our file naming conventions to documentation.
31
33
  __exportStar(require("./Flex"), exports);
32
34
  __exportStar(require("./Grid"), exports);
35
+ __exportStar(require("./nav-card"), exports);
36
+ __exportStar(require("./page-heading"), exports);
@@ -0,0 +1,83 @@
1
+ .nav-card {
2
+ background-color: var(--color-neutral-50);
3
+ border-radius: 0.35rem;
4
+ display: flex;
5
+ }
6
+
7
+ .nav-card__icon {
8
+ background-color: var(--color-gray-500);
9
+ border-bottom-left-radius: 0.25rem;
10
+ border-top-left-radius: 0.25rem;
11
+ color: var(--color-neutral-50);
12
+ display: flex;
13
+ align-items: center;
14
+ justify-content: center;
15
+ width: 180px;
16
+
17
+ /* Overriding SVG so you will not have to pass size prop to Icon component. */
18
+ svg {
19
+ width: 1.75rem !important;
20
+ height: 1.75rem !important;
21
+ }
22
+
23
+ /* Change bg color based on the class set on .nav-card */
24
+ &:is(.nav-card-akinon *) {
25
+ background-color: var(--color-akinon-500);
26
+ }
27
+
28
+ &:is(.nav-card-azure *) {
29
+ background-color: var(--color-azure-500);
30
+ }
31
+
32
+ &:is(.nav-card-blue *) {
33
+ background-color: var(--color-blue-500);
34
+ }
35
+
36
+ &:is(.nav-card-orange *) {
37
+ background-color: var(--color-orange-500);
38
+ }
39
+
40
+ &:is(.nav-card-red *) {
41
+ background-color: var(--color-red-500);
42
+ }
43
+
44
+ &:is(.nav-card-green *) {
45
+ background-color: var(--color-green-500);
46
+ }
47
+
48
+ &:is(.nav-card-pink *) {
49
+ background-color: var(--color-pink-500);
50
+ }
51
+
52
+ &:is(.nav-card-purple *) {
53
+ background-color: var(--color-purple-500);
54
+ }
55
+ }
56
+
57
+ .nav-card__content {
58
+ display: flex;
59
+ flex-direction: column;
60
+ justify-content: center;
61
+ align-items: flex-start;
62
+ padding: 1.5rem 1rem;
63
+ width: 100%;
64
+ }
65
+
66
+ .nav-card__title {
67
+ color: var(--color-ebonyClay-900);
68
+ font-size: 1.15rem;
69
+ font-weight: 500;
70
+ margin: 0;
71
+ padding: 0;
72
+ line-height: 1;
73
+ text-decoration: none;
74
+ }
75
+
76
+ .nav-card__description {
77
+ color: var(--color-gray-400);
78
+ font-weight: 400;
79
+ margin: 0.5rem 0 0;
80
+ padding: 0;
81
+ line-height: 1.3;
82
+ text-decoration: none;
83
+ }
@@ -0,0 +1,11 @@
1
+ import './nav-card.css';
2
+ import React, { ReactNode } from 'react';
3
+ export type NavCardColorVariant = 'akinon' | 'azure' | 'blue' | 'orange' | 'red' | 'green' | 'pink' | 'purple';
4
+ export interface NavCardProps {
5
+ title: string;
6
+ description: string;
7
+ icon?: ReactNode;
8
+ variant?: NavCardColorVariant;
9
+ }
10
+ export declare const NavCard: ({ title, description, icon, variant }: NavCardProps) => React.JSX.Element;
11
+ //# sourceMappingURL=nav-card.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"nav-card.d.ts","sourceRoot":"","sources":["../../src/nav-card.tsx"],"names":[],"mappings":"AAAA,OAAO,gBAAgB,CAAC;AAGxB,OAAO,KAAK,EAAE,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAEzC,MAAM,MAAM,mBAAmB,GAC3B,QAAQ,GACR,OAAO,GACP,MAAM,GACN,QAAQ,GACR,KAAK,GACL,OAAO,GACP,MAAM,GACN,QAAQ,CAAC;AAEb,MAAM,WAAW,YAAY;IAC3B,KAAK,EAAE,MAAM,CAAC;IACd,WAAW,EAAE,MAAM,CAAC;IACpB,IAAI,CAAC,EAAE,SAAS,CAAC;IACjB,OAAO,CAAC,EAAE,mBAAmB,CAAC;CAC/B;AAED,eAAO,MAAM,OAAO,0CAKjB,YAAY,sBAad,CAAC"}
@@ -0,0 +1,15 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.NavCard = void 0;
4
+ require("./nav-card.css");
5
+ const clsx_1 = require("clsx");
6
+ const react_1 = require("react");
7
+ const NavCard = ({ title, description, icon, variant }) => {
8
+ const variantClass = variant ? `nav-card-${variant}` : '';
9
+ return (react_1.default.createElement("div", { className: (0, clsx_1.default)('nav-card', variantClass) },
10
+ icon && react_1.default.createElement("div", { className: "nav-card__icon" }, icon),
11
+ react_1.default.createElement("div", { className: "nav-card__content" },
12
+ react_1.default.createElement("h2", { className: "nav-card__title" }, title),
13
+ react_1.default.createElement("div", { className: "nav-card__description" }, description))));
14
+ };
15
+ exports.NavCard = NavCard;
@@ -0,0 +1,27 @@
1
+ .akinon-page-heading {
2
+ border-bottom: 1px solid var(--color-ebonyClay-400);
3
+ display: flex;
4
+ justify-content: space-between;
5
+ align-items: center;
6
+ padding: 1.5rem 2rem;
7
+ }
8
+
9
+ .akinon-page-heading__content {
10
+ max-width: 50%;
11
+ }
12
+
13
+ .akinon-page-heading__title {
14
+ color: var(--color-neutral-50);
15
+ font-size: 1.25rem;
16
+ font-weight: 500;
17
+ margin: 0;
18
+ }
19
+
20
+ .akinon-page-heading__description {
21
+ color: var(--color-gray-300);
22
+ margin: 0;
23
+ padding: 0;
24
+ font-size: 13px;
25
+ font-weight: 400;
26
+ line-height: 1;
27
+ }
@@ -0,0 +1,9 @@
1
+ import './page-heading.css';
2
+ import React, { ReactNode } from 'react';
3
+ export interface PageHeadingProps {
4
+ title: string;
5
+ description?: string;
6
+ actions?: ReactNode;
7
+ }
8
+ export declare const PageHeading: ({ title, description, actions }: PageHeadingProps) => React.JSX.Element;
9
+ //# sourceMappingURL=page-heading.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"page-heading.d.ts","sourceRoot":"","sources":["../../src/page-heading.tsx"],"names":[],"mappings":"AAAA,OAAO,oBAAoB,CAAC;AAC5B,OAAO,KAAK,EAAE,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAEzC,MAAM,WAAW,gBAAgB;IAC/B,KAAK,EAAE,MAAM,CAAC;IACd,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,OAAO,CAAC,EAAE,SAAS,CAAC;CACrB;AAED,eAAO,MAAM,WAAW,oCAIrB,gBAAgB,sBAalB,CAAC"}
@@ -0,0 +1,13 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.PageHeading = void 0;
4
+ require("./page-heading.css");
5
+ const react_1 = require("react");
6
+ const PageHeading = ({ title, description, actions }) => {
7
+ return (react_1.default.createElement("div", { className: "akinon-page-heading" },
8
+ react_1.default.createElement("div", { className: "akinon-page-heading__content" },
9
+ react_1.default.createElement("h1", { className: "akinon-page-heading__title" }, title),
10
+ description && (react_1.default.createElement("p", { className: "akinon-page-heading__description" }, description))),
11
+ actions && react_1.default.createElement("div", { className: "akinon-page-heading__actions" }, actions)));
12
+ };
13
+ exports.PageHeading = PageHeading;
@@ -1,9 +1,3 @@
1
- /* TODO normalize cross-browser incosistencies */
2
- body {
3
- padding: 0;
4
- margin: 0;
5
- }
6
-
7
1
  .akinon-layout {
8
2
  &:not(.akinon-layout-has-sider) {
9
3
  border-inline: 1px solid var(--color-gray-900);
@@ -28,7 +22,6 @@ body {
28
22
  height: 100vh;
29
23
  overflow-y: auto;
30
24
 
31
- /* TODO normalize scrollbars. they took up huge space */
32
25
  &.left {
33
26
  inset-inline-start: 0;
34
27
  }
@@ -24,4 +24,6 @@ export type LeftSiderItem = {
24
24
  export { Layout };
25
25
  export * from './Flex';
26
26
  export * from './Grid';
27
+ export * from './nav-card';
28
+ export * from './page-heading';
27
29
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/index.tsx"],"names":[],"mappings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,EAAE,KAAK,EAAE,MAAM,SAAS,CAAC;AAEhC,KAAK,mBAAmB,GAAG,OAAO,cAAc,GAAG;IACjD,MAAM,EAAE,OAAO,MAAM,CAAC;IACtB,MAAM,EAAE,OAAO,MAAM,CAAC;IACtB,OAAO,EAAE,OAAO,OAAO,CAAC;IACxB,KAAK,EAAE,OAAO,KAAK,CAAC;CACrB,CAAC;AAEF,QAAA,MAAM,MAAM,EAAE,mBAKZ,CAAC;AAGH,MAAM,MAAM,aAAa,GAAG;IAC1B,GAAG,EAAE,MAAM,CAAC;IACZ,KAAK,EAAE,MAAM,CAAC;IACd,IAAI,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;IACvB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,OAAO,CAAC,EAAE,MAAM,IAAI,CAAC;IACrB,QAAQ,CAAC,EAAE,aAAa,EAAE,CAAC;IAC3B,QAAQ,CAAC,EAAE,OAAO,CAAC;CACpB,CAAC;AAEF,OAAO,EAAE,MAAM,EAAE,CAAC;AAGlB,cAAc,QAAQ,CAAC;AACvB,cAAc,QAAQ,CAAC;AACvB,cAAc,YAAY,CAAC;AAC3B,cAAc,gBAAgB,CAAC"}
package/dist/esm/index.js CHANGED
@@ -11,5 +11,9 @@ const Layout = Object.assign(InternalLayout, {
11
11
  Sider
12
12
  });
13
13
  export { Layout };
14
+ // TODO: Rename these files to be lowercase.
15
+ // TODO: Add our file naming conventions to documentation.
14
16
  export * from './Flex';
15
17
  export * from './Grid';
18
+ export * from './nav-card';
19
+ export * from './page-heading';
@@ -0,0 +1,83 @@
1
+ .nav-card {
2
+ background-color: var(--color-neutral-50);
3
+ border-radius: 0.35rem;
4
+ display: flex;
5
+ }
6
+
7
+ .nav-card__icon {
8
+ background-color: var(--color-gray-500);
9
+ border-bottom-left-radius: 0.25rem;
10
+ border-top-left-radius: 0.25rem;
11
+ color: var(--color-neutral-50);
12
+ display: flex;
13
+ align-items: center;
14
+ justify-content: center;
15
+ width: 180px;
16
+
17
+ /* Overriding SVG so you will not have to pass size prop to Icon component. */
18
+ svg {
19
+ width: 1.75rem !important;
20
+ height: 1.75rem !important;
21
+ }
22
+
23
+ /* Change bg color based on the class set on .nav-card */
24
+ &:is(.nav-card-akinon *) {
25
+ background-color: var(--color-akinon-500);
26
+ }
27
+
28
+ &:is(.nav-card-azure *) {
29
+ background-color: var(--color-azure-500);
30
+ }
31
+
32
+ &:is(.nav-card-blue *) {
33
+ background-color: var(--color-blue-500);
34
+ }
35
+
36
+ &:is(.nav-card-orange *) {
37
+ background-color: var(--color-orange-500);
38
+ }
39
+
40
+ &:is(.nav-card-red *) {
41
+ background-color: var(--color-red-500);
42
+ }
43
+
44
+ &:is(.nav-card-green *) {
45
+ background-color: var(--color-green-500);
46
+ }
47
+
48
+ &:is(.nav-card-pink *) {
49
+ background-color: var(--color-pink-500);
50
+ }
51
+
52
+ &:is(.nav-card-purple *) {
53
+ background-color: var(--color-purple-500);
54
+ }
55
+ }
56
+
57
+ .nav-card__content {
58
+ display: flex;
59
+ flex-direction: column;
60
+ justify-content: center;
61
+ align-items: flex-start;
62
+ padding: 1.5rem 1rem;
63
+ width: 100%;
64
+ }
65
+
66
+ .nav-card__title {
67
+ color: var(--color-ebonyClay-900);
68
+ font-size: 1.15rem;
69
+ font-weight: 500;
70
+ margin: 0;
71
+ padding: 0;
72
+ line-height: 1;
73
+ text-decoration: none;
74
+ }
75
+
76
+ .nav-card__description {
77
+ color: var(--color-gray-400);
78
+ font-weight: 400;
79
+ margin: 0.5rem 0 0;
80
+ padding: 0;
81
+ line-height: 1.3;
82
+ text-decoration: none;
83
+ }
@@ -0,0 +1,11 @@
1
+ import './nav-card.css';
2
+ import React, { ReactNode } from 'react';
3
+ export type NavCardColorVariant = 'akinon' | 'azure' | 'blue' | 'orange' | 'red' | 'green' | 'pink' | 'purple';
4
+ export interface NavCardProps {
5
+ title: string;
6
+ description: string;
7
+ icon?: ReactNode;
8
+ variant?: NavCardColorVariant;
9
+ }
10
+ export declare const NavCard: ({ title, description, icon, variant }: NavCardProps) => React.JSX.Element;
11
+ //# sourceMappingURL=nav-card.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"nav-card.d.ts","sourceRoot":"","sources":["../../src/nav-card.tsx"],"names":[],"mappings":"AAAA,OAAO,gBAAgB,CAAC;AAGxB,OAAO,KAAK,EAAE,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAEzC,MAAM,MAAM,mBAAmB,GAC3B,QAAQ,GACR,OAAO,GACP,MAAM,GACN,QAAQ,GACR,KAAK,GACL,OAAO,GACP,MAAM,GACN,QAAQ,CAAC;AAEb,MAAM,WAAW,YAAY;IAC3B,KAAK,EAAE,MAAM,CAAC;IACd,WAAW,EAAE,MAAM,CAAC;IACpB,IAAI,CAAC,EAAE,SAAS,CAAC;IACjB,OAAO,CAAC,EAAE,mBAAmB,CAAC;CAC/B;AAED,eAAO,MAAM,OAAO,0CAKjB,YAAY,sBAad,CAAC"}
@@ -0,0 +1,11 @@
1
+ import './nav-card.css';
2
+ import clsx from 'clsx';
3
+ import React from 'react';
4
+ export const NavCard = ({ title, description, icon, variant }) => {
5
+ const variantClass = variant ? `nav-card-${variant}` : '';
6
+ return (React.createElement("div", { className: clsx('nav-card', variantClass) },
7
+ icon && React.createElement("div", { className: "nav-card__icon" }, icon),
8
+ React.createElement("div", { className: "nav-card__content" },
9
+ React.createElement("h2", { className: "nav-card__title" }, title),
10
+ React.createElement("div", { className: "nav-card__description" }, description))));
11
+ };
@@ -0,0 +1,27 @@
1
+ .akinon-page-heading {
2
+ border-bottom: 1px solid var(--color-ebonyClay-400);
3
+ display: flex;
4
+ justify-content: space-between;
5
+ align-items: center;
6
+ padding: 1.5rem 2rem;
7
+ }
8
+
9
+ .akinon-page-heading__content {
10
+ max-width: 50%;
11
+ }
12
+
13
+ .akinon-page-heading__title {
14
+ color: var(--color-neutral-50);
15
+ font-size: 1.25rem;
16
+ font-weight: 500;
17
+ margin: 0;
18
+ }
19
+
20
+ .akinon-page-heading__description {
21
+ color: var(--color-gray-300);
22
+ margin: 0;
23
+ padding: 0;
24
+ font-size: 13px;
25
+ font-weight: 400;
26
+ line-height: 1;
27
+ }
@@ -0,0 +1,9 @@
1
+ import './page-heading.css';
2
+ import React, { ReactNode } from 'react';
3
+ export interface PageHeadingProps {
4
+ title: string;
5
+ description?: string;
6
+ actions?: ReactNode;
7
+ }
8
+ export declare const PageHeading: ({ title, description, actions }: PageHeadingProps) => React.JSX.Element;
9
+ //# sourceMappingURL=page-heading.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"page-heading.d.ts","sourceRoot":"","sources":["../../src/page-heading.tsx"],"names":[],"mappings":"AAAA,OAAO,oBAAoB,CAAC;AAC5B,OAAO,KAAK,EAAE,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAEzC,MAAM,WAAW,gBAAgB;IAC/B,KAAK,EAAE,MAAM,CAAC;IACd,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,OAAO,CAAC,EAAE,SAAS,CAAC;CACrB;AAED,eAAO,MAAM,WAAW,oCAIrB,gBAAgB,sBAalB,CAAC"}
@@ -0,0 +1,9 @@
1
+ import './page-heading.css';
2
+ import React from 'react';
3
+ export const PageHeading = ({ title, description, actions }) => {
4
+ return (React.createElement("div", { className: "akinon-page-heading" },
5
+ React.createElement("div", { className: "akinon-page-heading__content" },
6
+ React.createElement("h1", { className: "akinon-page-heading__title" }, title),
7
+ description && (React.createElement("p", { className: "akinon-page-heading__description" }, description))),
8
+ actions && React.createElement("div", { className: "akinon-page-heading__actions" }, actions)));
9
+ };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@akinon/ui-layout",
3
- "version": "0.3.0",
3
+ "version": "0.3.1",
4
4
  "private": false,
5
5
  "type": "module",
6
6
  "main": "dist/esm/index.js",
@@ -16,9 +16,9 @@
16
16
  "copyfiles": "^2.4.1",
17
17
  "rimraf": "^5.0.5",
18
18
  "typescript": "^5.2.2",
19
- "@akinon/vite-config": "0.3.0",
20
19
  "@akinon/eslint-config": "0.1.0",
21
- "@akinon/typescript-config": "0.1.0"
20
+ "@akinon/typescript-config": "0.1.0",
21
+ "@akinon/vite-config": "0.3.0"
22
22
  },
23
23
  "peerDependencies": {
24
24
  "react": ">=18",