@purr-react-styled-components/components.navbar 0.0.8 → 0.0.9
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/dist/index.cjs +22 -0
- package/dist/index.d.cts +14 -0
- package/dist/index.d.ts +14 -0
- package/dist/index.js +22 -0
- package/package.json +3 -3
package/dist/index.cjs
ADDED
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
'use strict';var f=require('clsx'),n=require('react'),e=require('styled-components');function _interopDefault(e){return e&&e.__esModule?e:{default:e}}var f__default=/*#__PURE__*/_interopDefault(f);var n__default=/*#__PURE__*/_interopDefault(n);var e__default=/*#__PURE__*/_interopDefault(e);var o=()=>e.css`
|
|
2
|
+
display: flex;
|
|
3
|
+
flex: 1;
|
|
4
|
+
justify-content: center;
|
|
5
|
+
align-items: center;
|
|
6
|
+
height: 100%;
|
|
7
|
+
`,t={Container:e__default.default.nav`
|
|
8
|
+
position: fixed;
|
|
9
|
+
top: 0;
|
|
10
|
+
left: 0;
|
|
11
|
+
right: 0;
|
|
12
|
+
display: flex;
|
|
13
|
+
justify-content: space-around;
|
|
14
|
+
align-items: center;
|
|
15
|
+
height: 56px;
|
|
16
|
+
`,Title:e__default.default.span`
|
|
17
|
+
${o};
|
|
18
|
+
`,LeftButton:e__default.default.span`
|
|
19
|
+
${o};
|
|
20
|
+
`,RightButton:e__default.default.span`
|
|
21
|
+
${o};
|
|
22
|
+
`};var y=({title:r,leftButton:a,rightButton:i,className:s,htmlAttributes:l})=>n__default.default.createElement(t.Container,{...l,className:f__default.default("navbar",s)},n__default.default.createElement(t.LeftButton,{className:"navbar__button navbar__button--left"},a),n__default.default.createElement(t.Title,{className:"navbar__title"},r),n__default.default.createElement(t.RightButton,{className:"navbar__button navbar__button--right"},i));exports.Navbar=y;
|
package/dist/index.d.cts
ADDED
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import React, { ReactNode, HTMLAttributes } from 'react';
|
|
2
|
+
import { IExtendable } from '@purr-core/utils.definitions';
|
|
3
|
+
|
|
4
|
+
interface INavbarProps {
|
|
5
|
+
className?: string;
|
|
6
|
+
leftButton?: ReactNode;
|
|
7
|
+
rightButton?: ReactNode;
|
|
8
|
+
title?: ReactNode;
|
|
9
|
+
htmlAttributes?: HTMLAttributes<HTMLDivElement> & IExtendable;
|
|
10
|
+
}
|
|
11
|
+
|
|
12
|
+
declare const Navbar: ({ title, leftButton, rightButton, className, htmlAttributes, }: INavbarProps) => React.JSX.Element;
|
|
13
|
+
|
|
14
|
+
export { type INavbarProps, Navbar };
|
package/dist/index.d.ts
ADDED
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import React, { ReactNode, HTMLAttributes } from 'react';
|
|
2
|
+
import { IExtendable } from '@purr-core/utils.definitions';
|
|
3
|
+
|
|
4
|
+
interface INavbarProps {
|
|
5
|
+
className?: string;
|
|
6
|
+
leftButton?: ReactNode;
|
|
7
|
+
rightButton?: ReactNode;
|
|
8
|
+
title?: ReactNode;
|
|
9
|
+
htmlAttributes?: HTMLAttributes<HTMLDivElement> & IExtendable;
|
|
10
|
+
}
|
|
11
|
+
|
|
12
|
+
declare const Navbar: ({ title, leftButton, rightButton, className, htmlAttributes, }: INavbarProps) => React.JSX.Element;
|
|
13
|
+
|
|
14
|
+
export { type INavbarProps, Navbar };
|
package/dist/index.js
ADDED
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import f from'clsx';import n from'react';import e,{css}from'styled-components';var o=()=>css`
|
|
2
|
+
display: flex;
|
|
3
|
+
flex: 1;
|
|
4
|
+
justify-content: center;
|
|
5
|
+
align-items: center;
|
|
6
|
+
height: 100%;
|
|
7
|
+
`,t={Container:e.nav`
|
|
8
|
+
position: fixed;
|
|
9
|
+
top: 0;
|
|
10
|
+
left: 0;
|
|
11
|
+
right: 0;
|
|
12
|
+
display: flex;
|
|
13
|
+
justify-content: space-around;
|
|
14
|
+
align-items: center;
|
|
15
|
+
height: 56px;
|
|
16
|
+
`,Title:e.span`
|
|
17
|
+
${o};
|
|
18
|
+
`,LeftButton:e.span`
|
|
19
|
+
${o};
|
|
20
|
+
`,RightButton:e.span`
|
|
21
|
+
${o};
|
|
22
|
+
`};var y=({title:r,leftButton:a,rightButton:i,className:s,htmlAttributes:l})=>n.createElement(t.Container,{...l,className:f("navbar",s)},n.createElement(t.LeftButton,{className:"navbar__button navbar__button--left"},a),n.createElement(t.Title,{className:"navbar__title"},r),n.createElement(t.RightButton,{className:"navbar__button navbar__button--right"},i));export{y as Navbar};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@purr-react-styled-components/components.navbar",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.9",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"main": "dist/index.cjs",
|
|
6
6
|
"module": "dist/index.js",
|
|
@@ -24,10 +24,10 @@
|
|
|
24
24
|
"typescript": "*",
|
|
25
25
|
"react": "*",
|
|
26
26
|
"clsx": "*",
|
|
27
|
-
"@purr-core/utils.definitions": "0.0.
|
|
27
|
+
"@purr-core/utils.definitions": "0.0.12"
|
|
28
28
|
},
|
|
29
29
|
"devDependencies": {
|
|
30
|
-
"@purr-react-styled-components/components.button": "0.0.
|
|
30
|
+
"@purr-react-styled-components/components.button": "0.0.9"
|
|
31
31
|
},
|
|
32
32
|
"author": "@DinhThienPhuc",
|
|
33
33
|
"license": "ISC",
|