├── .nvmrc ├── .gitignore ├── .npmrc ├── .eslintignore ├── src ├── index.js.example ├── setupTests.js ├── index.js └── svg-loader-components │ ├── oval.js │ ├── tail-spin.js │ ├── hearts.js │ ├── audio.js │ ├── puff.js │ ├── three-dots.js │ ├── circles.js │ ├── ball-triangle.js │ ├── rings.js │ ├── grid.js │ ├── bars.js │ └── spinning-circles.js ├── .babelrc ├── test ├── bars.test.js ├── grid.test.js ├── oval.test.js ├── puff.test.js ├── audio.test.js ├── rings.test.js ├── hearts.test.js ├── circles.test.js ├── tail-spin.test.js ├── three-dots.test.js ├── ball-triangle.test.js └── spinning-circles.test.js ├── .github └── workflows │ └── publish.yml ├── .travis.yml ├── webpack.config.js ├── LICENSE.md ├── .eslintrc.js ├── README.md ├── package.json └── dist └── index.js /.nvmrc: -------------------------------------------------------------------------------- 1 | v20 2 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | /node_modules 2 | -------------------------------------------------------------------------------- /.npmrc: -------------------------------------------------------------------------------- 1 | legacy-peer-deps=true 2 | -------------------------------------------------------------------------------- /.eslintignore: -------------------------------------------------------------------------------- 1 | /node_modules/ 2 | /dist/ 3 | webpack.config.js -------------------------------------------------------------------------------- /src/index.js.example: -------------------------------------------------------------------------------- 1 | export * from './svg-loader-components/example.js' 2 | -------------------------------------------------------------------------------- /.babelrc: -------------------------------------------------------------------------------- 1 | { 2 | "presets": ["@babel/preset-env", "@babel/preset-react"], 3 | "plugins": [ 4 | "@babel/plugin-proposal-object-rest-spread", 5 | "transform-react-jsx" 6 | ] 7 | } -------------------------------------------------------------------------------- /src/setupTests.js: -------------------------------------------------------------------------------- 1 | import 'jsdom-global/register'; 2 | 3 | import { configure } from 'enzyme'; 4 | import Adapter from '@cfaester/enzyme-adapter-react-18'; 5 | 6 | configure({ adapter: new Adapter() }); 7 | -------------------------------------------------------------------------------- /test/bars.test.js: -------------------------------------------------------------------------------- 1 | import React from 'react'; 2 | import { shallow, mount } from 'enzyme'; 3 | 4 | import { Bars } from '../src/svg-loader-components/bars'; 5 | 6 | describe('Test ', () => { 7 | it('renders without crashing', () => { 8 | shallow(); 9 | }); 10 | it('viewBox property is defined', () => { 11 | const BarsComponent = mount().find('svg'); 12 | expect(BarsComponent.prop('viewBox')).toBeDefined(); 13 | }); 14 | }); 15 | -------------------------------------------------------------------------------- /test/grid.test.js: -------------------------------------------------------------------------------- 1 | import React from 'react'; 2 | import { shallow, mount } from 'enzyme'; 3 | 4 | import { Grid } from '../src/svg-loader-components/grid'; 5 | 6 | describe('Test ', () => { 7 | it('renders without crashing', () => { 8 | shallow(); 9 | }); 10 | it('viewBox property is defined', () => { 11 | const GridComponent = mount().find('svg'); 12 | expect(GridComponent.prop('viewBox')).toBeDefined(); 13 | }); 14 | }); 15 | -------------------------------------------------------------------------------- /test/oval.test.js: -------------------------------------------------------------------------------- 1 | import React from 'react'; 2 | import { shallow, mount } from 'enzyme'; 3 | 4 | import { Oval } from '../src/svg-loader-components/oval'; 5 | 6 | describe('Test ', () => { 7 | it('renders without crashing', () => { 8 | shallow(); 9 | }); 10 | it('viewBox property is defined', () => { 11 | const OvalComponent = mount().find('svg'); 12 | expect(OvalComponent.prop('viewBox')).toBeDefined(); 13 | }); 14 | }); 15 | -------------------------------------------------------------------------------- /test/puff.test.js: -------------------------------------------------------------------------------- 1 | import React from 'react'; 2 | import { shallow, mount } from 'enzyme'; 3 | 4 | import { Puff } from '../src/svg-loader-components/puff'; 5 | 6 | describe('Test ', () => { 7 | it('renders without crashing', () => { 8 | shallow(); 9 | }); 10 | it('viewBox property is defined', () => { 11 | const PuffComponent = mount().find('svg'); 12 | expect(PuffComponent.prop('viewBox')).toBeDefined(); 13 | }); 14 | }); 15 | -------------------------------------------------------------------------------- /test/audio.test.js: -------------------------------------------------------------------------------- 1 | import React from 'react'; 2 | import { shallow, mount } from 'enzyme'; 3 | 4 | import { Audio } from '../src/svg-loader-components/audio'; 5 | 6 | describe('Test