Base for creating buttons with ShadowUI.

Usage no npm install needed!

<script type="module">
  import shadowUiButton from 'https://cdn.skypack.dev/@shadow-ui/button';



Version Downloads Build License

๐Ÿ“ฆ @inspire11-ui/button

This package is a collection of Inspire11 banners for use in CLI tooling. These banners are difficult to hardcode in JavaScript/TypeScript projects because of how the characters ', ", and ``` are used stylistically. Further, we can't just the Node filesystem or dynamic imports because we'll quickly run into errors out in the wild with NPX. This workaround bundles our banners with webpack from from easy-to-manage text files and allows us to reliably add Inspire11 branding to our CLI projects.

  1. ๐Ÿ’ผ Getting Started 1.1 ๐Ÿ“š Prerequisites 1.2 ๐Ÿ“ฒ Installing
  2. ๐Ÿ›  Testing 2.1 ๐Ÿ” E2E 2.2 ๐Ÿ› Static Analysis
  3. ๐Ÿ›ฅ Deployment
  4. ๐Ÿงพ Important Dependencies
  5. ๐Ÿ™Œ๐Ÿผ Contributing
  6. ๐Ÿท Versioning
  7. ๐Ÿ“œ Authors
  8. ๐Ÿ“„ License
  9. ๐Ÿ“ฏ Acknowledgments

๐Ÿ’ผ Getting Started

These instructions will get you a copy of the project up and running on your local machine for development and testing purposes. See deployment for notes on how to deploy the project on a live system.

๐Ÿ“š Prerequisites

What things you need to install the software and how to install them

Give examples

๐Ÿ“ฒ Installing

To install the package, clone and build the repo, then use npm to install dependencies.

git clone git@bitbucket.org:inspire11/button.git
cd button
npm i

๐Ÿ›ฅ Deployment

To push changes and use new button, update the package version and publish to NPM:

git version patch
npm publish --access=public

๐Ÿงพ Important Dependencies

  • TypeScript - Implementation language
  • NPM - Dependency Management
  • Webpack - The build pipeline used
  • Babel - JavaScript/TypeScript transpiler

๐Ÿ™Œ๐Ÿผ Contributing

To add a banner to this package, create a text file with the format {{bannerName}}.txt:

touch {{bannerName}}.txt

You can find ideas for your banner here, or use your own. Once you've got a banner, add it to {{bannerName}}.txt. Then, add the following to index.ts:

import {{bannerName}} from './{{bannerName}}.txt';

Webpack uses raw-loader to inject the contents imported from {{bannerName}}.txt into the distributed compiled JavaScript so that we don't have to read or import {{bannerName}}.txt at runtime.

In order to easily access your banner in other projects, you should include at least 3 exports:

  • 1 export of the text imported from './{{bannerName}}.txt'
  • 1 export of a function which returns the text imported from './{{bannerName}}.txt'
  • 1 export of a function which logts the text imported from './{{bannerName}}.txt'
export const {{bannerName}}Banner: string = {{bannerName}};
export const get{{bannerName}}Banner = (): string => {{bannerName}};
export const log{{bannerName}}Banner = (): void => console.log({{bannerName}});

Finally, add these exports to the default export object at the bottom of index.ts:

export default {

Please read CONTRIBUTING.md for details on our code of conduct, and the process for submitting pull requests to us.

๐Ÿท Versioning

We use SemVer for versioning. For the versions available, see the tags on this repository.

๐Ÿ“œ Authors

See also the list of contributors who participated in this project.

๐Ÿ“„ License

This project is licensed under the MIT License - see the LICENSE.md file for details

๐Ÿ“ฏ Acknowledgments

  • Hat tip to anyone whose code was used
  • Inspiration
  • etc