Skip to content

Commit ab06cce

Browse files
authored
Configure Doctocat (#21)
1 parent 047a6bb commit ab06cce

38 files changed

+63733
-35
lines changed

.changeset/spicy-rivers-begin.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
"@primer/react-brand": patch
3+
---
4+
5+
Remove fixed background color from `Hero` to allow underlying customisation to be surfaced.

.eslintrc.json

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -141,6 +141,7 @@
141141
},
142142
"rules": {
143143
"camelcase": 0,
144+
"import/no-unresolved": 0,
144145
"no-constant-condition": 0,
145146
"no-console": 0,
146147
"no-empty-pattern": 0,
@@ -152,6 +153,7 @@
152153
"react/jsx-key": 0,
153154
"react/jsx-no-comment-textnodes": 0,
154155
"import/no-anonymous-default-export": 0,
156+
"import/extensions": 0,
155157
"prettier/prettier": 0,
156158
"@typescript-eslint/no-unnecessary-condition": 0,
157159
"@typescript-eslint/no-unused-vars": 0,

.github/workflows/ci.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -30,15 +30,15 @@ jobs:
3030
- name: Install dependencies
3131
run: npm ci
3232

33+
- name: Build
34+
run: npm run build
35+
3336
- name: Run linters
3437
run: npm run lint
3538

3639
- name: Check formatting
3740
run: npm run format
3841

39-
- name: Build
40-
run: npm run build
41-
4242
- name: Verify types
4343
run: npm run check
4444

.github/workflows/deploy_storybook.yml renamed to .github/workflows/deploy_docs.yml

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
name: Deploy Storybook to production
1+
name: Deploy docs to production
22

33
on:
44
push:
@@ -34,11 +34,14 @@ jobs:
3434
- name: Install dependencies
3535
run: npm ci
3636

37-
- name: Build storybook
38-
run: npm run build:storybook
37+
- name: Build library
38+
run: npm run build
39+
40+
- name: Build docs
41+
run: npm run build:docs
3942

4043
- name: Archive build output
41-
run: 'tar --dereference --directory storybook-static/ -cvf artifact.tar .'
44+
run: 'tar --dereference --directory docs/public/ -cvf artifact.tar .'
4245

4346
- name: Upload artifact
4447
uses: actions/upload-artifact@main

.github/workflows/deploy_storybook_preview.yml renamed to .github/workflows/deploy_docs_preview.yml

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
name: Deploy Storybook Preview to Pages
1+
name: Deploy docs preview to Pages
22

33
on:
44
pull_request:
@@ -32,11 +32,14 @@ jobs:
3232
- name: Install dependencies
3333
run: npm ci
3434

35-
- name: Build storybook
36-
run: npm run build:storybook
35+
- name: Build library
36+
run: npm run build
37+
38+
- name: Build docs
39+
run: npm run build:docs
3740

3841
- name: Archive build output
39-
run: 'tar --dereference --directory storybook-static/ -cvf artifact.tar .'
42+
run: 'tar --dereference --directory docs/public -cvf artifact.tar .'
4043

4144
- name: Upload artifact
4245
uses: actions/upload-artifact@main

.storybook/preview.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,8 @@ import '../lib/css/gh-variables.color.css'
55
export const globalTypes = {
66
colorMode: {
77
name: 'Color mode',
8-
description: 'Color mode (day, night, auto, all)',
9-
defaultValue: 'day',
8+
description: 'Color mode (light, dark, auto, all)',
9+
defaultValue: 'light',
1010
toolbar: {
1111
icon: 'globe',
1212
// array of colorMode items

.vscode/settings.json

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,13 @@
11
{
22
"typescript.tsdk": "node_modules/typescript/lib",
3-
"editor.formatOnSave": true
3+
"editor.formatOnSave": true,
4+
"[javascript]": {
5+
"editor.defaultFormatter": "esbenp.prettier-vscode"
6+
},
7+
"[typescript]": {
8+
"editor.defaultFormatter": "esbenp.prettier-vscode"
9+
},
10+
"[typescriptreact]": {
11+
"editor.defaultFormatter": "esbenp.prettier-vscode"
12+
}
413
}

LICENSE

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
MIT License
22

3-
Copyright (c) 2022 Primer
3+
Copyright (c) 2022 GitHub Inc.
44

55
Permission is hereby granted, free of charge, to any person obtaining a copy
66
of this software and associated documentation files (the "Software"), to deal

README.md

Lines changed: 39 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,40 @@
1-
# @primer/react-brand
1+
<p align="center">
2+
<img width="300px" src="https://user-images.githubusercontent.com/4608155/127241386-f11da52d-00d9-4366-b01c-6f4c1ebcf7f2.png">
3+
</p>
24

3-
TODO
5+
<h1 align="center">Primer React Brand</h1>
6+
7+
<p align="center">A React implementation of GitHub's Brand Design System</p>
8+
9+
<p align="center">
10+
<a aria-label="npm package" href="https://www.npmjs.com/package/@primer/react-brand">
11+
<img alt="" src="https://img.shields.io/npm/v/@primer/react-brand.svg">
12+
</a>
13+
<a aria-label="build status" href="https://github.com/primer/react-brand/actions/workflows/ci.yml">
14+
<img alt="" src="https://github.com/primer/react-brand/actions/workflows/ci.yml/badge.svg">
15+
</a>
16+
<img src="https://img.shields.io/badge/status-experimental-red" alt="status: experimental">
17+
<a aria-label="license" href="https://github.com/primer/react-brand/blob/main/LICENSE">
18+
<img src="https://img.shields.io/github/license/primer/react-brand.svg" alt="">
19+
</a>
20+
</p>
21+
22+
<p align="center">
23+
<a href="https://primer.github.io/react-brand/" target="_blank">https://primer.github.io/react-brand</a>
24+
</p>
25+
26+
## Install
27+
28+
This repository is distributed on [npm]. After [installing npm](https://docs.npmjs.com/downloading-and-installing-node-js-and-npm), you can install `@primer/react-brand` as a dependency of your project:
29+
30+
```sh
31+
npm install @primer/react-brand
32+
```
33+
34+
## Usage
35+
36+
See our [getting started guide](https://primer.github.io/react-brand/getting-started) for more information.
37+
38+
## License
39+
40+
[MIT](./LICENSE) &copy; [GitHub](https://github.com/)

docs/.github/dependabot.yml

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
# To get started with Dependabot version updates, you'll need to specify which
2+
# package ecosystems to update and where the package manifests are located.
3+
# Please see the documentation for all configuration options:
4+
# https://help.github.com/github/administering-a-repository/configuration-options-for-dependency-updates
5+
6+
version: 2
7+
updates:
8+
- package-ecosystem: "npm" # See documentation for possible values
9+
directory: "/" # Location of package manifests
10+
schedule:
11+
interval: "daily"
12+
allow:
13+
- dependency-name: "@primer/gatsby-theme-doctocat"

0 commit comments

Comments
 (0)