-
-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
19d0cd9
commit 49e23bf
Showing
12 changed files
with
2,737 additions
and
119 deletions.
There are no files selected for viewing
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,47 @@ | ||
import commonjs from "@rollup/plugin-commonjs"; | ||
import resolve from "@rollup/plugin-node-resolve"; | ||
import typescript from "@rollup/plugin-typescript"; | ||
import dts from "rollup-plugin-dts"; | ||
import peerDepsExternal from 'rollup-plugin-peer-deps-external'; | ||
import postcss from "rollup-plugin-postcss"; | ||
//NEW | ||
import { terser } from "rollup-plugin-terser"; | ||
|
||
|
||
const packageJson = require("./package.json"); | ||
|
||
export default [ | ||
{ | ||
input: "src/index.ts", | ||
output: [ | ||
{ | ||
file: packageJson.main, | ||
format: "cjs", | ||
sourcemap: true, | ||
}, | ||
{ | ||
file: packageJson.module, | ||
format: "esm", | ||
sourcemap: true, | ||
}, | ||
], | ||
plugins: [ | ||
// NEW | ||
peerDepsExternal(), | ||
|
||
resolve(), | ||
commonjs(), | ||
typescript({ tsconfig: "./tsconfig.json" }), | ||
postcss(), | ||
|
||
// NEW | ||
terser(), | ||
], | ||
}, | ||
{ | ||
input: "dist/esm/types/index.d.ts", | ||
output: [{ file: "dist/index.d.ts", format: "esm" }], | ||
plugins: [dts()], | ||
external: [/\.css$/], | ||
}, | ||
]; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,15 +1 @@ | ||
import React, { FC, HTMLAttributes, ReactChild } from 'react'; | ||
|
||
export interface Props extends HTMLAttributes<HTMLDivElement> { | ||
/** custom content, defaults to 'the snozzberries taste like snozzberries' */ | ||
children?: ReactChild; | ||
} | ||
|
||
// Please do not use types off of a default export module or else Storybook Docs will suffer. | ||
// see: https://github.com/storybookjs/storybook/issues/9556 | ||
/** | ||
* A custom Thing component. Neat! | ||
*/ | ||
export const Thing: FC<Props> = ({ children }) => { | ||
return <div>{children || `the snozzberries taste like snozzberries`}</div>; | ||
}; | ||
export * from "./GhostNavbar/GhostNavbar"; |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
import { Meta } from '@storybook/react'; | ||
import React from "react"; | ||
import { GhostNavbar } from '../src/GhostNavbar/GhostNavbar'; | ||
|
||
const meta: Meta = { | ||
title: 'Ghost Navbar', | ||
component: GhostNavbar, | ||
}; | ||
|
||
export default meta | ||
|
||
export const Default = ()=> <GhostNavbar styles={{navigationBackground:{backgroundColor: 'red'}}}/> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
const postcss = require('rollup-plugin-postcss'); | ||
|
||
module.exports = { | ||
rollup(config, options) { | ||
config.plugins.push( | ||
postcss({ | ||
inject: false, | ||
extract: !!options.writeMeta, | ||
}), | ||
); | ||
return config; | ||
}, | ||
}; |
Oops, something went wrong.