Skip to content

Commit

Permalink
final formatting options
Browse files Browse the repository at this point in the history
  • Loading branch information
thescientist13 committed May 3, 2024
1 parent 5f88ef6 commit 1a1a1ed
Show file tree
Hide file tree
Showing 15 changed files with 226 additions and 254 deletions.
10 changes: 1 addition & 9 deletions .prettierrc
Original file line number Diff line number Diff line change
@@ -1,11 +1,3 @@
{
"singleQuote": false,
"overrides": [
{
"files": ["**/*.js"],
"options": {
"singleQuote": true
}
}
]
"printWidth": 100
}
12 changes: 4 additions & 8 deletions .storybook/main.js
Original file line number Diff line number Diff line change
@@ -1,17 +1,13 @@
/** @type { import('@storybook/web-components-vite').StorybookConfig } */
const config = {
stories: ['../src/**/*.mdx', '../src/**/*.stories.@(js|jsx|mjs|ts|tsx)'],
addons: [
'@storybook/addon-links',
'@storybook/addon-essentials',
'@chromatic-com/storybook',
],
stories: ["../src/**/*.mdx", "../src/**/*.stories.@(js|jsx|mjs|ts|tsx)"],
addons: ["@storybook/addon-links", "@storybook/addon-essentials", "@chromatic-com/storybook"],
framework: {
name: '@storybook/web-components-vite',
name: "@storybook/web-components-vite",
options: {},
},
docs: {
autodocs: 'tag',
autodocs: "tag",
},
};

Expand Down
4 changes: 2 additions & 2 deletions .storybook/preview.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import '../src/styles/theme.css';
import '../src/styles/main.css';
import "../src/styles/theme.css";
import "../src/styles/main.css";

/** @type { import('@storybook/web-components').Preview } */
const preview = {
Expand Down
20 changes: 8 additions & 12 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Contributing

Thanks for contributing to the GreenwoodJS website! This document aims to help guide contributions into this project.
Thanks for contributing to the GreenwoodJS website! This document aims to help guide contributions into this project.

## Project Structure

Expand All @@ -12,14 +12,13 @@ The layout of the project is as follows:
- _/stories/_ - General developer documentation about the project for developers
- _/styles/_ - Global theme and styles

> [!NOTE]
> _Please review the documentation contained in this project's Storybook by running `npm run story:dev` and going through the content in the **Overview** section_
> [!NOTE] > _Please review the documentation contained in this project's Storybook by running `npm run story:dev` and going through the content in the **Overview** section_
## Documentation Changes

### Greenwood Features

Documentation changes specific to an in progress / unreleased feature in Greenwood should be made to the corresponding feature branch in this repository aligning with that Greenwood release. This can be determined at the time of submitting your PR to Greenwood in coordination with the maintainers.
Documentation changes specific to an in progress / unreleased feature in Greenwood should be made to the corresponding feature branch in this repository aligning with that Greenwood release. This can be determined at the time of submitting your PR to Greenwood in coordination with the maintainers.

For example, if the next release your feature is targeting for Greenwood is 1.1.0, the git workflow would be as follows:

Expand All @@ -31,18 +30,17 @@ $ git checkout -b content/issue-xxx-the-feature

Where `issue-xxx` is the corresponding issue in the GreenwoodJS project.


### Website

General changes to the website can be made by submitting a PR directly to the main branch. This includes typos, style changes, and general enhancements to the website as a whole.
General changes to the website can be made by submitting a PR directly to the main branch. This includes typos, style changes, and general enhancements to the website as a whole.

## Development

### Styling

All global theming and general styles should go in _src/styles/theme.css_, like font family and CSS custom properties to be used throughout the site.

[Open Props](https://open-props.style/) are used in this project to provide a set of consistent and re-usable design system tokens. Please review these first before creating any new custom values or variables.
[Open Props](https://open-props.style/) are used in this project to provide a set of consistent and re-usable design system tokens. Please review these first before creating any new custom values or variables.

### Components

Expand All @@ -63,8 +61,7 @@ export default class MyComponent extends HTMLElement {
<script src="../components/my-component/my-component.js" type="module" data-gwd-opt="static">
```
> [!TIP]
> _For highly interactive components **without** a strong need for static content and / or SEO, Declarative Shadow DOM can be used instead._
> [!TIP] > _For highly interactive components **without** a strong need for static content and / or SEO, Declarative Shadow DOM can be used instead._
The CSS for any Light DOM components should go into _src/styles/main.css_
Expand All @@ -75,7 +72,6 @@ The CSS for any Light DOM components should go into _src/styles/main.css_
}
```
### Testing
For each component, a testing file should be included to test basic functionality, living alongside the component in its directory.
Expand All @@ -89,7 +85,7 @@ components/
### Storybook
For each component, a Storybook file should be included to demonstrate basic functionality, living alongside the component in its directory. Generally a default story should be sufficient.
For each component, a Storybook file should be included to demonstrate basic functionality, living alongside the component in its directory. Generally a default story should be sufficient.
```sh
components/
Expand All @@ -100,4 +96,4 @@ components/
## Hosting and Deployment
This project is hosted on Netlify and automatically deploys on each merge into main. Release branches will be curated over the course of a Greenwood release cycle and then merged at the time the new Greenwood release is published to NPM.
This project is hosted on Netlify and automatically deploys on each merge into main. Release branches will be curated over the course of a Greenwood release cycle and then merged at the time the new Greenwood release is published to NPM.
Loading

0 comments on commit 1a1a1ed

Please sign in to comment.