Skip to content

Commit

Permalink
init
Browse files Browse the repository at this point in the history
init
  • Loading branch information
root authored and dominikhaid committed Oct 5, 2021
1 parent c4ce5a8 commit 146e827
Show file tree
Hide file tree
Showing 3,279 changed files with 34,716 additions and 326,998 deletions.
The diff you're trying to view is too large. We only load the first 3000 changed files.
14 changes: 0 additions & 14 deletions .babelrc

This file was deleted.

4 changes: 0 additions & 4 deletions .dockerignore

This file was deleted.

11 changes: 11 additions & 0 deletions .env.development
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
HOST=http://localhost
PORT=3000
ORIGINS= http://localhost,https://www.dominikhaid.de
PUBLIC_FOLDER=public

HELMET_DEFAULT= http://localhost https://www.dominikhaid.de
HELMET_SCRIPTS= http://localhost https://code.jquery.com https://www.dominikhaid.de https://fonts.gstatic.com


CERTIFICATE=./certificates/localhostcert
CERTIFICATE_KEY=./certificates/localhostkey
11 changes: 11 additions & 0 deletions .env.production
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
HOST=https://dominikhaid.de
PORT=80
ORIGINS= https://dominikhaid.de,https://www.dominikhaid.de
PUBLIC_FOLDER=public

HELMET_DEFAULT= https://dominikhaid.de https://www.dominikhaid.de
HELMET_SCRIPTS= https://dominikhaid.de https://code.jquery.com https://www.dominikhaid.de https://fonts.gstatic.com


CERTIFICATE=./certificates/localhostcert
CERTIFICATE_KEY=./certificates/localhostkey
24 changes: 20 additions & 4 deletions .eslintrc
Original file line number Diff line number Diff line change
@@ -1,18 +1,34 @@
// Install packages
// npm install --save-dev prettier eslint-config-airbnb eslint-config-prettier eslint-plugin-prettier eslint-plugin-react eslint-plugin-import eslint-plugin-jsx-a11y husky lint-staged

{
"extends": [
"eslint:recommended",
"react-app",
"airbnb",
"plugin:import/errors",
"plugin:react/recommended",
"plugin:jsx-a11y/recommended",
"prettier",
"plugin:prettier/recommended",
"prettier/react"
],
"settings": {
"import/resolver": {
"alias": {
"map": [
["components", "./src/components"],
["lib", "./src/lib"],
["src", "./src/"],
["public", "./public"],
["data","./src/data"],
["context","./src/context"],
["hooks","./src/hooks"],
["routers","./src/routers"],
["reducers","./src/reducers"],
["includes","./src/includes"]

],
"extensions": [".ts", ".js", ".jsx", ".json",".css",".less",".scss"]
}
}
},
"plugins": ["react", "import", "prettier", "jsx-a11y"],
"parser": "babel-eslint",
"parserOptions": {
Expand Down
20 changes: 13 additions & 7 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,13 +1,19 @@
**/gitignore
.env.development
.env.production
/log
/logs
/.next
# .env.development
# .env.production
.next
**/build
/node_modules
**/samples
**/certificates
/docker-backups
**/node_modules
/out
.editorconfig
**/debug.log
package-lock.json
out
**/storybook-static
**/log/.*log
.editorconfig
**.log
log/access.log
**.lock
4 changes: 3 additions & 1 deletion .prettierrc.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,5 +8,7 @@
"bracketSpacing": false,
"jsxBracketSameLine": false,
"arrowParens": "avoid",
"proseWrap": "always"
"proseWrap": "always",
"endOfLine":"lf",
"embeddedLanguageFormatting":"auto"
}
83 changes: 83 additions & 0 deletions .storybook/main.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,83 @@
const path = require('path');

module.exports = {
stories: [
'../src/stories/**/*.stories.js',
//'../src/components/**/*.stories.js',
],
addons: [
'@storybook/addon-links',
'@storybook/addon-essentials',
'@storybook/addon-storysource',
'@storybook/addon-actions',
'storycap',
'storybook-addon-designs',
'@storybook/addon-controls',
],
webpackFinal: async config => {
const rules = config.module.rules.map(rule => {
if (/svg/.test(rule.test))
rule.test = /\.(ico|jpg|jpeg|png|apng|gif|webp|cur|ani|pdf)(\?.*)?$/;
return rule;
});

config.module.rules = rules;

config.module.rules.push({
test: /\.less$/,
use: [
'style-loader',
{
loader: 'css-loader',
options: {
modules: false,
// localIdentName: '[local]___[hash:base64:5]',
},
},
{
loader: 'less-loader',
options: {
lessOptions: {
javascriptEnabled: true,
},
},
},
],
include: path.resolve(__dirname, '../src'),
});

config.module.rules.unshift({
test: /\.svg$/,
use: ['@svgr/webpack'],
include: path.resolve(__dirname, '../'),
});

config.module.rules.unshift({
test: /\.(woff|woff2|eot|ttf)/,
loaders: ['file-loader'],
include: path.resolve(__dirname, '../'),
});

config.resolve.alias['components'] = path.resolve(
__dirname,
'../src/components',
);
config.resolve.alias['lib'] = path.resolve(__dirname, '../src/lib');
config.resolve.alias['src'] = path.resolve(__dirname, '../src');
config.resolve.alias['data'] = path.resolve(__dirname, '../src/data');
config.resolve.alias['context'] = path.resolve(__dirname, '../src/context');
config.resolve.alias['hooks'] = path.resolve(__dirname, '../src/hooks');
config.resolve.alias['routers'] = path.resolve(__dirname, '../src/routers');
config.resolve.alias['reducers'] = path.resolve(
__dirname,
'../src/reducers',
);
config.resolve.alias['includes'] = path.resolve(
__dirname,
'../src/includes',
);
config.resolve.alias['public'] = path.resolve(__dirname, '../public');

return config;
},
};
107 changes: 107 additions & 0 deletions .storybook/preview.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,107 @@
import Tailwind from '../public/css/global.css';
import WeatherIcons from 'public/css/weather-icons-core.css';
import StorbookCss from './stroybook.css';

import React from 'react';
import {withNextRouter} from 'storybook-addon-next-router';
import {addDecorator} from '@storybook/react';
import '@storybook/addon-console';
import {setConsoleOptions} from '@storybook/addon-console';
import {withConsole} from '@storybook/addon-console';
import {withScreenshot} from 'storycap';
import {configure} from '@storybook/react';

// import {setDefaults} from 'react-storybook-addon-props-combinations';

// setDefaults({
// // overwrite global defaults here
// });

// configure(() => {
// // ...
// }, module);

addDecorator((storyFn, context) => withConsole()(storyFn)(context));

setConsoleOptions({
panelExclude: [],
});

addDecorator(
withNextRouter({
path: '/',
asPath: '/',
query: {},
push() {},
}),
);

import {INITIAL_VIEWPORTS} from '@storybook/addon-viewport';

const customViewports = {
kindleFire2: {
name: 'Kindle Fire 2',
styles: {
width: '600px',
height: '963px',
},
},
kindleFireHD: {
name: 'Kindle Fire HD',
styles: {
width: '533px',
height: '801px',
},
},
};

export const decorators = [
withScreenshot,
Story => (
<>
<Story />
</>
),
];

export const parameters = {
backgrounds: {
default: 'light',
values: [
{
name: 'light',
value: '#fff',
},
{
name: 'dark',
value: '#041E34',
},
],
},
screenshot: {
viewports: {
large: {
width: 2560,
height: 1440,
},
medium: 'Kindle Fire HDX landscape',
small: 'iPad',
xsmall: 'iPhone 5',
},
delay: 500,
},
viewport: {
viewports: {
...INITIAL_VIEWPORTS,
...customViewports,
},
},
actions: {argTypesRegex: '^on[A-Z].*'},
// Storybook a11y addon configuration
a11y: {
// the target DOM element
element: '#root',
// sets the execution mode for the addon
manual: false,
},
};
38 changes: 38 additions & 0 deletions .storybook/stroybook.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
@import url('https://fonts.googleapis.com/css2?family=Roboto&display=swap');

@font-face {
font-family: 'weathericons';
src: url('/fonts/weather/weathericons-regular-webfont.eot');
src: url('/fonts/weather/weathericons-regular-webfont.eot?#iefix')
format('embedded-opentype'),
url('/fonts/weather/weathericons-regular-webfont.woff2') format('woff2'),
url('/fonts/weather/weather/weathericons-regular-webfont.woff')
format('woff'),
url('/fonts/weather/weathericons-regular-webfont.ttf') format('truetype'),
url('/fonts/weather/weathericons-regular-webfont.svg#weather_iconsregular')
format('svg');
font-weight: normal;
font-style: normal;
}

#__next {
min-height: 850px !important;
}

nav#main-menu {
min-height: 850px !important;
}

fieldset,
fieldset > * {
height: fit-content;
}

@media screen and (max-width: 765px) {
#__next {
/*display: inherit !important;*/
min-height: unset !important;
padding-top: 0rem;
padding-bottom: 0rem;
}
}
Loading

0 comments on commit 146e827

Please sign in to comment.