Skip to content

Commit 3a3e478

Browse files
committed
release: v4.0.0-alpha.0
0 parents  commit 3a3e478

File tree

430 files changed

+107701
-0
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

430 files changed

+107701
-0
lines changed

.editorconfig

+12
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
# EditorConfig is awesome: https://EditorConfig.org
2+
3+
# top-most EditorConfig file
4+
root = true
5+
6+
[*]
7+
indent_style = space
8+
indent_size = 2
9+
end_of_line = lf
10+
charset = utf-8
11+
trim_trailing_whitespace = false
12+
insert_final_newline = false

.eslinignore

+3
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
{
2+
"ignorePatterns": [".eslintrc.js", ".docz/**/*"]
3+
}

.eslintrc.js

+28
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
module.exports = {
2+
parser: '@typescript-eslint/parser', // Specifies the ESLint parser
3+
parserOptions: {
4+
ecmaVersion: 2020, // Allows for the parsing of modern ECMAScript features
5+
sourceType: 'module', // Allows for the use of imports
6+
ecmaFeatures: {
7+
jsx: true, // Allows for the parsing of JSX
8+
},
9+
},
10+
settings: {
11+
react: {
12+
version: 'detect', // Tells eslint-plugin-react to automatically detect the version of React to use
13+
},
14+
},
15+
extends: [
16+
'plugin:jsdoc/recommended',
17+
'plugin:react/recommended', // Uses the recommended rules from @eslint-plugin-react
18+
'plugin:@typescript-eslint/recommended', // Uses the recommended rules from the @typescript-eslint/eslint-plugin
19+
'prettier/@typescript-eslint', // Uses eslint-config-prettier to disable ESLint rules from @typescript-eslint/eslint-plugin that would conflict with prettier
20+
'plugin:prettier/recommended', // Enables eslint-plugin-prettier and eslint-config-prettier. This will display prettier errors as ESLint errors. Make sure this is always the last configuration in the extends array.
21+
],
22+
plugins: ['jsdoc', '@typescript-eslint', 'react', 'react-hooks'],
23+
rules: {
24+
// Place to specify ESLint rules. Can be used to overwrite rules specified from the extended configs
25+
// e.g. "@typescript-eslint/explicit-function-return-type": "off",
26+
'react/prop-types': 'off',
27+
},
28+
}

.github/CODE_OF_CONDUCT.md

+46
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,46 @@
1+
# Contributor Covenant Code of Conduct
2+
3+
## Our Pledge
4+
5+
In the interest of fostering an open and welcoming environment, we as contributors and maintainers pledge to making participation in our project and our community a harassment-free experience for everyone, regardless of age, body size, disability, ethnicity, gender identity and expression, level of experience, nationality, personal appearance, race, religion, or sexual identity and orientation.
6+
7+
## Our Standards
8+
9+
Examples of behavior that contributes to creating a positive environment include:
10+
11+
* Using welcoming and inclusive language
12+
* Being respectful of differing viewpoints and experiences
13+
* Gracefully accepting constructive criticism
14+
* Focusing on what is best for the community
15+
* Showing empathy towards other community members
16+
17+
Examples of unacceptable behavior by participants include:
18+
19+
* The use of sexualized language or imagery and unwelcome sexual attention or advances
20+
* Trolling, insulting/derogatory comments, and personal or political attacks
21+
* Public or private harassment
22+
* Publishing others' private information, such as a physical or electronic address, without explicit permission
23+
* Other conduct which could reasonably be considered inappropriate in a professional setting
24+
25+
## Our Responsibilities
26+
27+
Project maintainers are responsible for clarifying the standards of acceptable behavior and are expected to take appropriate and fair corrective action in response to any instances of unacceptable behavior.
28+
29+
Project maintainers have the right and responsibility to remove, edit, or reject comments, commits, code, wiki edits, issues, and other contributions that are not aligned to this Code of Conduct, or to ban temporarily or permanently any contributor for other behaviors that they deem inappropriate, threatening, offensive, or harmful.
30+
31+
## Scope
32+
33+
This Code of Conduct applies both within project spaces and in public spaces when an individual is representing the project or its community. Examples of representing a project or community include using an official project e-mail address, posting via an official social media account, or acting as an appointed representative at an online or offline event. Representation of a project may be further defined and clarified by project maintainers.
34+
35+
## Enforcement
36+
37+
Instances of abusive, harassing, or otherwise unacceptable behavior may be reported by contacting the project team at . The project team will review and investigate all complaints, and will respond in a way that it deems appropriate to the circumstances. The project team is obligated to maintain confidentiality with regard to the reporter of an incident. Further details of specific enforcement policies may be posted separately.
38+
39+
Project maintainers who do not follow or enforce the Code of Conduct in good faith may face temporary or permanent repercussions as determined by other members of the project's leadership.
40+
41+
## Attribution
42+
43+
This Code of Conduct is adapted from the [Contributor Covenant][homepage], version 1.4, available at [http://contributor-covenant.org/version/1/4][version]
44+
45+
[homepage]: http://contributor-covenant.org
46+
[version]: http://contributor-covenant.org/version/1/4/

.github/COMMIT_CONVENTION.md

+83
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,83 @@
1+
## Git Commit Message Convention
2+
3+
> This is adapted from [Angular's commit convention](https://github.com/conventional-changelog/conventional-changelog/blob/master/packages/conventional-changelog-angular/convention.md).
4+
5+
#### Examples
6+
7+
Appears under "Features" header, `compiler` subheader:
8+
9+
```
10+
feat(compiler): add 'comments' option
11+
```
12+
13+
Appears under "Bug Fixes" header, `sidebar` subheader, with a link to issue #28:
14+
15+
```
16+
fix(sidebar): handle events on blur
17+
18+
close #28
19+
```
20+
21+
Appears under "Performance Improvements" header, and under "Breaking Changes" with the breaking change explanation:
22+
23+
```
24+
perf(core): improve vdom diffing by removing 'foo' option
25+
26+
BREAKING CHANGE: The 'foo' option has been removed.
27+
```
28+
29+
The following commit and commit `667ecc1` do not appear in the changelog if they are under the same release. If not, the revert commit appears under the "Reverts" header.
30+
31+
```
32+
revert: feat(compiler): add 'comments' option
33+
34+
This reverts commit 667ecc1654a317a13331b17617d973392f415f02.
35+
```
36+
37+
### Full Message Format
38+
39+
A commit message consists of a **header**, **body** and **footer**. The header has a **type**, **scope** and **subject**:
40+
41+
```
42+
<type>(<scope>): <subject>
43+
<BLANK LINE>
44+
<body>
45+
<BLANK LINE>
46+
<footer>
47+
```
48+
49+
The **header** is mandatory and the **scope** of the header is optional.
50+
51+
### Revert
52+
53+
If the commit reverts a previous commit, it should begin with `revert: `, followed by the header of the reverted commit. In the body it should say: `This reverts commit <hash>.`, where the hash is the SHA of the commit being reverted.
54+
55+
### Type
56+
57+
If the prefix is `feat`, `fix` or `perf`, it will appear in the changelog. However if there is any [BREAKING CHANGE](#footer), the commit will always appear in the changelog.
58+
59+
Other prefixes are up to your discretion. Suggested prefixes are `docs`, `chore`, `style`, `refactor`, and `test` for non-changelog related tasks.
60+
61+
### Scope
62+
63+
The scope could be anything specifying place of the commit change. For example `core`, `compiler`, `ssr`, `v-model`, `transition` etc...
64+
65+
### Subject
66+
67+
The subject contains succinct description of the change:
68+
69+
* use the imperative, present tense: "change" not "changed" nor "changes"
70+
* don't capitalize first letter
71+
* no dot (.) at the end
72+
73+
### Body
74+
75+
Just as in the **subject**, use the imperative, present tense: "change" not "changed" nor "changes".
76+
The body should include the motivation for the change and contrast this with previous behavior.
77+
78+
### Footer
79+
80+
The footer should contain any information about **Breaking Changes** and is also the place to
81+
reference GitHub issues that this commit **Closes**.
82+
83+
**Breaking Changes** should start with the word `BREAKING CHANGE:` with a space or two newlines. The rest of the commit message is then used for this.

.github/CONTRIBUTING.md

+34
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
# Contributing
2+
3+
## Usage
4+
5+
```bash
6+
# Install dependencies
7+
npm install
8+
9+
# Build
10+
npm run build
11+
12+
# Run all tests with lint/jest
13+
npm run test
14+
15+
# Run test in watch mode
16+
npm run test:watch
17+
18+
# Update test snapshot
19+
npm run test:update
20+
21+
# Run linter
22+
npm run lint
23+
24+
# Run linter with auto fix
25+
npm run lint:fix
26+
```
27+
## Workflow
28+
29+
- Create a component in the src/components folder
30+
- Add tests in the src/components/\_\_tests\_\_ folder
31+
- Register this component in src/index.js
32+
- Run lint and tests before commiting anything
33+
- Commit using [Commit Convention](./COMMIT_CONVENTION.md)
34+
- PR on github

.github/ISSUE_TEMPLATE.md

+26
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
Before opening an issue:
2+
3+
- [Search for duplicate or closed issues](https://github.com/coreui/coreui-react/issues?utf8=%E2%9C%93&q=is%3Aissue)
4+
- Prepare a [reduced test case](https://css-tricks.com/reduced-test-cases/) for any bugs
5+
- Read the [contributing guidelines](./CONTRIBUTING.md)
6+
7+
When asking general "how to" questions:
8+
9+
- Please do not open an issue here
10+
- Post your question here - https://community.coreui.io/c/support/coreui-for-react/15
11+
12+
When reporting a bug, include:
13+
14+
- Operating system and version (Windows, Mac OS X, Android, iOS, etc...)
15+
- Browser and version (Chrome, Firefox, Safari, IE, MS Edge, Opera 15+, Android Browser)
16+
- Reduced test cases and potential fixes using [CodePen](https://codepen.io/) or [JS Bin](https://jsbin.com/)
17+
18+
When suggesting a feature:
19+
20+
- Please do not open an issue here,
21+
- Post your feature request here - https://community.coreui.io/c/feature-requests/12
22+
- Include:
23+
- As much detail as possible for what we should add and why it's important to CoreUI for React.js
24+
- Relevant links to prior art, screenshots, or live demos whenever possible
25+
26+
**Please use GitHub only when reporting a bug, all issues with the general "how to" questions will be automatically closed.**

.github/PULL_REQUEST_TEMPLATE.md

+35
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
<!--
2+
Please make sure to read the Pull Request Guidelines:
3+
https://github.com/coreui/coreui-react/.github/CONTRIBUTING.md#pull-request-guidelines
4+
-->
5+
6+
<!-- PULL REQUEST TEMPLATE -->
7+
<!-- (Update "[ ]" to "[x]" to check a box) -->
8+
9+
**What kind of change does this PR introduce?** (check at least one)
10+
11+
- [ ] Bugfix
12+
- [ ] Feature
13+
- [ ] Code style update
14+
- [ ] Refactor
15+
- [ ] Build-related changes
16+
- [ ] Other, please describe:
17+
18+
**Does this PR introduce a breaking change?** (check one)
19+
20+
- [ ] Yes
21+
- [ ] No
22+
23+
If yes, please describe the impact and migration path for existing applications:
24+
25+
**The PR fulfills these requirements:**
26+
27+
- [ ] It's submitted to the `develop` branch (or to a previous version branch), _not_ the `master` branch
28+
- [ ] When resolving a specific issue, it's referenced in the PR's title (e.g. `fix #xxx[,#xxx]`, where "xxx" is the issue number)
29+
- [ ] All tests are passing
30+
- [ ] New/updated tests are included
31+
32+
If adding a **new feature**, the PR's description includes:
33+
- [ ] A convincing reason for adding this feature (to avoid wasting your time, it's best to open a suggestion issue first and wait for approval before working on it)
34+
35+
**Other information:**
+31
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
name: Daily project check
2+
3+
on:
4+
schedule:
5+
# build runs every weekday at 6AM UTC
6+
- cron: '0 6 * * 1-5'
7+
8+
jobs:
9+
build:
10+
11+
runs-on: ubuntu-latest
12+
13+
strategy:
14+
matrix:
15+
node-version: [12.x]
16+
os: [ubuntu-latest, windows-latest, macOS-latest]
17+
18+
steps:
19+
- uses: actions/checkout@v1
20+
- name: Use Node.js ${{ matrix.node-version }}
21+
uses: actions/setup-node@v1
22+
with:
23+
node-version: ${{ matrix.node-version }}
24+
- name: npm install, build, test and lint
25+
run: |
26+
npm i
27+
npm run build
28+
npm run jest:test
29+
npm run lint
30+
env:
31+
CI: true

.github/workflows/project-check.yml

+34
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
name: Project check
2+
3+
on:
4+
push:
5+
branches:
6+
- master
7+
pull_request:
8+
branches:
9+
- master
10+
11+
jobs:
12+
build:
13+
14+
runs-on: ubuntu-latest
15+
16+
strategy:
17+
matrix:
18+
node-version: [12.x]
19+
os: [ubuntu-latest, windows-latest, macOS-latest]
20+
21+
steps:
22+
- uses: actions/checkout@v1
23+
- name: Use Node.js ${{ matrix.node-version }}
24+
uses: actions/setup-node@v1
25+
with:
26+
node-version: ${{ matrix.node-version }}
27+
- name: npm install, build, test and lint
28+
run: |
29+
npm i
30+
npm run build
31+
npm run jest:test
32+
npm run lint
33+
env:
34+
CI: true

.gitignore

+4
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
.docz
2+
dist/
3+
coverage/
4+
node_modules/

.prettierignore

+1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
dist/

.prettierrc.js

+7
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
module.exports = {
2+
semi: false,
3+
trailingComma: "all",
4+
singleQuote: true,
5+
printWidth: 100,
6+
tabWidth: 2
7+
};

.vscode/settings.json

+3
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
{
2+
"editor.defaultFormatter": "esbenp.prettier-vscode"
3+
}

0 commit comments

Comments
 (0)