Skip to content

Commit

Permalink
Upgrade to v4.0 (#265)
Browse files Browse the repository at this point in the history
* Upgrade Bulma; add spacing modifiers

* Remove List component

* Update CHANGELOG.md

* Move bulma to peerDependencies

* Bump lodash from 4.17.15 to 4.17.19

Bumps [lodash](https://github.com/lodash/lodash) from 4.17.15 to 4.17.19.
- [Release notes](https://github.com/lodash/lodash/releases)
- [Commits](lodash/lodash@4.17.15...4.17.19)

Signed-off-by: dependabot[bot] <support@github.com>

* Remove yarn.lock

* Audited packages

* fix: add missing Table.Container element (#274)

* fix: add missing Table.Container element

* Address review feedback

* fix: add missing table hoverable prop (#273)

* Rewrite TypeScript Definitions (#252)

* Define <Element /> and <Box /> component types

* Add typedefs for more components

* Add typedefs for more components

* Try to add support for renderAs prop

* brute forced every single html elements to apply dynamic props based on renderAs

* removed some html elements because too many cases breaks ts

* removed more html elements for renderAs props

* removed more html elements for renderAs props

* Tries to fix renderAs dynamic prop typing

* Clean up the code

* Add types for more components

* Tidy up code

* Add types for more components

* Add types for the remaining components

* clean up the code

* remove ref attribute; fix menu type def

* Add Table.Container type

* Add Table hoverable prop

* Remove List component

* Remove sass and all dependencies #262  (#278)

* remove sass and all dependencies

* Fix eslint issues

* update dev dependencies

* update Readme

* Fix prettier errors

* fix button ref test

* change Object.keys for Object.values

* WIP: split some component typedefs into individual files.

* Move index typedef to root

* Move index typedef to src

* Move rest of component typedefs into their own files

* Trying to make tree-shaking work

* Add clickable helper

* Update bulma peer dep to 0.9.1

* Fix jest tests not able to run

* Upgrade bulma peer dep to 0.9.2

* Refactor responsive modifier props

* Change storybook import alias

* Rewrite import statements in stories to use named exports

* Update typedefs

* Fix Jest tests

* Fix decreased test coverage

* Add support for flexbox helpers; add spacing helpers typedef

* Add pagination first last pages (#283)

* feat: add pagination first last pages originally done by @haflinger

- ref: #100

* feat: add story for the showFirstLast feature in pagination

* feat: add size, position and rounded props to pagination

* fix: remove duplicated checking on first/last page btns

* feat: update typescript def for the new pagination props

* Add test case for showFirstLast prop

Co-authored-by: Kenneth Ng <ngcreeper@outlook.com>

* Add missing TypeScript exports

* Add documentation (#251)

* init documentation

* fix dependencies

* import only used components

* Improve docs distribution
create folder/files structure

* Add npm script for starting docs website

* Add columns basic documentation

* documentation (#266)

* documentation

* Update card.md

* Update tiles.md

* Update box.md

* Update card.md

* Update content.md

* Update media.md

* new

* Update gap.md

* Update nesting.md

* Update options.md

* Update responsiveness.md

* Update card.md

* Update dropdown.md

* Update menu.md

* Update message.md

* Update navbar.md

* Update pagination.md

* Update panel.md

* Update tabs.md

* Update box.md

* Update button.md

* Update icon.md

* Update notification.md

* Update progress-bar.md

* Update tag.md

* Update container.md

* Update level.md

* new

* new

* new

* Tidy up code

* Update column size documentation

* Fix small typo in column size doc

* Update column responsiveness doc

* Update column nesting doc

* Accidentally removed Section import in column nesting doc

* Add missing code example in column responsiveness doc

* Update column gap doc

* Update column options doc

* Update column basics doc

* Update container doc

* Update level doc

Co-authored-by: Kenneth <kenneth.ng.5226@outlook.com>

* Update bulma to 3.4.0

* Add pagination first last pages (documentation) (#284)

* docs: add doc for pagination first/last btns, size, position and rounded

* chore: code consistency

Co-authored-by: John Benavides <john.elric@gmail.com>
Co-authored-by: Quadri Sheriff <59125401+Quadrisheriff@users.noreply.github.com>
Co-authored-by: Yuen Ying Kit <yingkityuen@gmail.com>

* Documentation: Use `next` branch of library

* Update pagination documentation

* Update import statements in docs

* Fix incorrect type path

* Fix incorrect type path

* Update README.md

* Move old logo to documentations folder

* Fix incorrect bulma version

* Fix missing array type for Select

* Remove Button state prop

* Fix Warning: Failed prop type: Invalid prop value supplied to Select (#288)

* Fix Warning: Failed prop type: Invalid prop value supplied to Select

* Fix stylistic issues
- Format code with Prettier
- Use double quote for JSX strings
- Introduce local defaultValue function

* Remove tests that check no error is thrown

* Fix defaultValue function

* Group Select value PropTypes tests

* Move value PropTypes tests in Select component group

* Use dot notation

* Change input-file to a controled component

* 4.0.0-0

* update typescript definitions for input-file

* Implement state props for Form.Input

* Remove loading prop from Form.Input

* Add rounded prop to Form.Input

* Migrate to storybook addon-docs from docusaurus (#289)

* Add addon-essentials storybook plugin

* Rewrite <Box /> doc

* WIP: implement breadcrumb doc

* WIP: Implement Breadcrumb doc

* Implement Breadcrumb doc

* Update box doc

* Add button doc

* Implement Card doc

* Add theme to storybook

* WIP: Add column doc

* Add Columns doc

* Add Columns doc

* Add Container doc

* Add Content doc

* WIP: add dropdown doc

* Add Dropdown doc

* Add Footer doc

* Implement Form doc

* WIP: add Form.Input doc

* Implement Form.Input doc

* Document rounded prop of Form.Input

* Allow override of renderAs of Form.Input; remove default HTML attrs propTypes

* Add is-flex helper support

* Also support other display classes via display modifier prop

* Forgot to apply display prop to class names; fix test

* Support text size 7

* Add support for font family modifiers

* Add is-sr-only modifier support

* Add doc landing page; Add renderAs and modifier doc

* Add checkbox doc

* Remove some deprecated packages; audited packages

* Revert storybook upgrade

* WIP: Textarea doc

* Add some missing Form.Textarea props

* Add Textarea doc; remove Element story code

* Remove loading prop from Form.Textarea and Form.Input

* Add rounded props for Form.Select

* WIP: add Select doc

* Finish Select doc

* Add various state props for Select

* Add Radio doc

* Fix failing InputFile test

* Rename InputFile value prop to files; update InputFile type

* Add Menu doc

* Add message doc

* Fix missing Modal ts props

* Fixes issues with modal children (#302) (#303)

* Revert "Fix missing Modal ts props"

This reverts commit f2e1a0a.

* Update modal types to include document, children, classname

* Add string column widths to types (#304)

* 4.0.0-1

* Add Breadcrumb.Item component to replace Breadcrumb items prop (#293)

* WIP: Add Breadcrumb.Item component

* Add test and types for Breadcrumb.Item

* Add centered prop to InputFile

* Add InputFile doc

* Add InputFile prop table

* Add InputFile label control

* Heading will now render appropriate header element based on supplied size.

* Revert prev commit

* Add Heading doc

* Add missing m/p spacing helpers

* Use default export on component level ts definition (#308)

* add icon to dropdown props definition (#310)

Co-authored-by: Matt McCorry <matt@auktechnologies.com>

* 4.0.0-2

* Update docs and improve/normalize components props (#309)

* Update columns docs

* add Block component

* fix tests

* more docs

* add more components to the docs

* added all elements

* Add missing links to bulma.io documentation

* [WIP] use Element.proptypes and defaultProps instead of modifier

* update can i use

* use Element proptypes ans defaultprops

* breadcrumb component

* add card

* refactor dropdow to stop using class component

* dropdown docs

* Menu component

* Enable classProperties in babel

* Fix storybook webpack issue

* Add level doc

* Message docs

* Fix render as a color constants

* add bulma docs link to message story

* update modal component

* update snapshots

* remove modifier dependency

* remove modifiers folder

* if button type its reset or submit force renderAs button

* remove modifiers import from d.ts files

* finish Element docs (for now)

* normalize normalize position (center -> centered)

* docs improvements

* delete documentation folder

* more default props

* fixes

* update reponsive text alignment

* Rename textAlignment to textAlign

* even more...

* refactor pagination to functional component

* remove babel plugin not need it anymore

* update dependencies

* add pagination docs

* Panel docs

* tabs docs

* dome Form component docs

* Fix input tests

* Texta area and tests

* Select docs

* Checkbox

* Radio docs

* Add label story

* Passdown size prop from Field to childrens

* update test and lower coverage (for now)

* Finish form docs

* remove unused files

* - Container Docs
- Remove Fluid from container
- Add fluid as a possible value of breakpoint
- Add Max prop to container

* Level docs

* rename position to align

* update Changelog

* remove Media.Content component (duplicates Content Component)

* Hero

* Add Section docs

* Update Footer docs

* add Tile docs

* remove notification and color props from Tile

* improve Tile docs

* Improve responsive gap prop

* remove unused mock

Co-authored-by: Kenneth <kenneth.ng.5226@outlook.com>

* 4.0.0-RC.0

* - Normalize align on Navbar.Container
- Add size to Navbar (is-spaced)
- Normalize non-responsive display prop
- Add invisible prop to all components
- Ignore size on Hero if hasNavbar is true

* small fixes

* 4.0.0-RC.1

* add relative to display prop allowed values

* add text prop to icon component

* Fix build and tests

* improve order of common proptypes

* Fix #313 add size as optional prop

* Fix issue with RenderAsComponent type (#316)

Uses ElementType (https://flow.org/en/docs/react/types/#toc-react-elementtype) to fix #314

* Allow Color and size custom props
Add Color custom&extend docs

* - Fix tests
- Remove proptypes from bundle

* normalize Statues

* Improve Changelog

* 4.0.0-RC.2

* Test package configurations

* Add hero halfheight size

* Fix test runner

* Allow pass IconType to control to use on isIcon function

* 4.0.0-RC.3

* update bulma peer dependency

* fix package json files field

* 4.0.0-RC.4

* include ts definitions on package

* 4.0.0-RC.5

* add shades as valid buttons colors

* fix imports on TS (Gatsby)

* 4.0.0-RC.6

* add cjs and esm builds

* 4.0.0-RC.7

* Fix Menu.Item.List children proptype

* More improvements

* 4.0.0-RC.8

* build library as a prepublish step

* add renderAs to TagGroup

* fix prepublish script

* update travis to node 14

* regenerate package-lock

* Try to fix CI

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>
Co-authored-by: John <john.elric@gmail.com>
Co-authored-by: Yuen Ying Kit <yingkityuen@gmail.com>
Co-authored-by: Quadri Sheriff <59125401+Quadrisheriff@users.noreply.github.com>
Co-authored-by: 1r3n33 <59848434+1r3n33@users.noreply.github.com>
Co-authored-by: John Benavides <john.benavides@gartner.com>
Co-authored-by: David Smith <davepwsmith@users.noreply.github.com>
Co-authored-by: Matt McCorry <mccorry@gmail.com>
Co-authored-by: Matt McCorry <matt@auktechnologies.com>
  • Loading branch information
11 people committed Apr 24, 2021
1 parent dc696e2 commit eba2e62
Show file tree
Hide file tree
Showing 377 changed files with 21,923 additions and 40,096 deletions.
10 changes: 0 additions & 10 deletions .babelrc

This file was deleted.

6 changes: 4 additions & 2 deletions .eslintignore
Original file line number Diff line number Diff line change
Expand Up @@ -4,5 +4,7 @@ full/**
lib/**
node_modules
reports
*.story.js
*.test.js
*.test.js
**/*.d.ts
documentation/**
.coverage
5 changes: 4 additions & 1 deletion .eslintrc
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,9 @@
"react/forbid-foreign-prop-types": 0,
"jsx-a11y/anchor-is-valid": 0,
"react/destructuring-assignment": 0,
"jsx-a11y/label-has-associated-control": 0
"jsx-a11y/label-has-associated-control": 0,
"react/require-default-props": 0,
"react/default-props-match-prop-types": 0,
"react/prop-types": 0
}
}
3 changes: 1 addition & 2 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -68,9 +68,8 @@ typings/
out*

/reports
/dist
/lib
/full
/cjs
.coverage
.vscode
.cache
3 changes: 2 additions & 1 deletion .npmignore
Original file line number Diff line number Diff line change
Expand Up @@ -14,4 +14,5 @@ reports
.coveralls.yml
.travis.yml
.yarnclean
jest.json
jest.json
**/__test__
1 change: 1 addition & 0 deletions .nvmrc
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
v12.22.1
8 changes: 0 additions & 8 deletions .storybook/addons.js

This file was deleted.

25 changes: 25 additions & 0 deletions .storybook/common-props.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
import React, { useState } from 'react';
import { ArgsTable } from '@storybook/addon-docs/blocks';
import { Block, Message, Button } from '../'
import Element from '../src/components/element'

const CommonProps = () => {
const [show, setShow] = useState()
return (
<>
<Block>
<Message color="info">
<Message.Body textSize={7}>
This component also has all the shared props from the <code>Element</code> component {' '}
<a onClick={() => setShow(s => !s)}>{show ? 'Hide' : 'Show'} common props</a>
</Message.Body>
</Message>
{
show && <ArgsTable of={Element} />
}
</Block>
</>
)
};

export default CommonProps
41 changes: 0 additions & 41 deletions .storybook/config.js

This file was deleted.

18 changes: 0 additions & 18 deletions .storybook/extra-viewports.json

This file was deleted.

43 changes: 43 additions & 0 deletions .storybook/main.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
const path = require('path');
const { DefinePlugin } = require('webpack');

module.exports = {
stories: ['../src/**/*.story.mdx'],
addons: [
'@storybook/addon-essentials',
{
name: '@storybook/addon-storysource',
options: {
rule: {
test: [/\.story\.js?$/],
},
},
},
'@storybook/addon-knobs',
'@storybook/addon-links',
'@storybook/addon-events',
'@storybook/addon-viewport',
'@storybook/addon-postcss',
'storybook-addon-react-docgen',
'@storybook/preset-scss',
],
webpackFinal: (config) => {
config.devtool = 'source-maps';
config.resolve.modules.push('node_modules', 'src');
config.resolve.alias['react-bulma-components/lib'] = path.resolve(
__dirname,
'../src',
);
config.resolve.alias['react-bulma-components'] = path.resolve(
__dirname,
'../src',
);
config.plugins.push(
new DefinePlugin({
process: JSON.stringify(true),
}),
);

return config;
},
};
6 changes: 6 additions & 0 deletions .storybook/manager.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
import { addons } from '@storybook/addons';
import theme from './theme';

addons.setConfig({
theme,
});
3 changes: 3 additions & 0 deletions .storybook/package.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
{
"type": "commonjs"
}
106 changes: 0 additions & 106 deletions .storybook/preview-head.html

This file was deleted.

60 changes: 60 additions & 0 deletions .storybook/preview.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,60 @@
import { addDecorator } from '@storybook/react';
import { withPropsTable } from 'storybook-addon-react-docgen';
import { MINIMAL_VIEWPORTS} from '@storybook/addon-viewport';

import test from './rewrites.scss'
import '@fortawesome/fontawesome-free/css/all.min.css';

console.log(test);

addDecorator(withPropsTable);

export const parameters = {
layout: 'padded',
viewMode: 'docs',
viewport: {
viewports: {
...MINIMAL_VIEWPORTS,
"tablet": {
"name": "Tablet",
"styles": {
"width": "1023px",
"height": "963px"
},
"type": "tablet"
},
"desktop": {
"name": "Desktop",
"styles": {
"width": "1215px",
"height": "100%"
},
"type": "desktop"
},
"widescreen": {
"name": "Widescreen",
"styles": {
"width": "1407px",
"height": "100%"
},
"type": "desktop"
},
"fullhd": {
"name": "Fullhd",
"styles": {
"width": "1920px",
"height": "100%"
},
"type": "desktop"
},
}
},
options: {
storySort: {
order: ['Welcome', 'Changelog', 'Core Component', 'Columns', 'Elements', 'Components', 'Form', 'Layout'],
},
},
previewTabs: {
'storybook/docs/panel': { index: 0, default: true },
}
};

0 comments on commit eba2e62

Please sign in to comment.