Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Vite migration #154

Open
wants to merge 15 commits into
base: develop
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
44 changes: 44 additions & 0 deletions .eslintrc.cjs
@@ -0,0 +1,44 @@
module.exports = {
root: true,
env: { browser: true, es2020: true },
extends: [
"eslint:recommended",
"plugin:react/recommended",
"plugin:react/jsx-runtime",
"plugin:react-hooks/recommended",
],
ignorePatterns: ["dist", ".eslintrc.cjs"],
parserOptions: { ecmaVersion: "latest", sourceType: "module" },
settings: { react: { version: "18.2" } },
plugins: ["react-refresh", "simple-import-sort", "import"],
rules: {
"react-refresh/only-export-components": [
"warn",
{ allowConstantExport: true },
],
"simple-import-sort/imports": [
"error",
{
groups: [
["^\\u0000"],
["^@?\\w"],
[
"^(actions|components|eventManagers|middleware|reducers|serverPropTypes|style|utils)",
],
["^"],
["^\\."],
],
},
],
"import/first": "error",
"import/newline-after-import": "error",
"import/no-duplicates": "error",
"max-len": [
"error",
{
code: 88,
},
],
quotes: [1, "single"],
},
};
50 changes: 21 additions & 29 deletions .gitignore
@@ -1,34 +1,26 @@
# See https://help.github.com/articles/ignoring-files/ for more about ignoring files.

# dependencies
/node_modules
/.pnp
.pnp.js

# testing
/coverage

# production
/build

# misc
.DS_Store
.env.local
.env.development.local
.env.test.local
.env.production.local

# Logs
logs
*.log
npm-debug.log*
yarn-debug.log*
yarn-error.log*
pnpm-debug.log*
lerna-debug.log*

node_modules
dist
dist-ssr
*.local

# Editor directories and files
.vscode/*
!.vscode/extensions.json
.idea
.DS_Store
*.suo
*.ntvs*
*.njsproj
*.sln
*.sw?

# Vim stuff
*.sw[po]
*.vim
*.lvimrc

# Backups
*~

# Builds
/dakara*.zip
24 changes: 12 additions & 12 deletions .stylelintrc.json
@@ -1,14 +1,14 @@
{
"extends": "stylelint-config-sass-guidelines",
"rules": {
"color-named": "always-where-possible",
"function-parentheses-space-inside": "never-single-line",
"indentation": 4,
"max-nesting-depth": 99,
"scss/selector-no-redundant-nesting-selector": null,
"selector-max-compound-selectors": 9,
"selector-max-id": 1,
"selector-no-qualifying-type": [false, {"ignore": ["attribute", "class"]}],
"string-quotes": "double"
}
"extends": "stylelint-config-sass-guidelines",
"rules": {
"color-named": "always-where-possible",
"function-parentheses-space-inside": "never-single-line",
"indentation": 4,
"max-nesting-depth": 99,
"scss/selector-no-redundant-nesting-selector": null,
"selector-max-compound-selectors": 9,
"selector-max-id": 1,
"selector-no-qualifying-type": [null, { "ignore": ["attribute", "class"] }],
"string-quotes": "double"
}
}
8 changes: 8 additions & 0 deletions CHANGELOG.md
Expand Up @@ -30,6 +30,14 @@

## Unreleased

### Added

- Player errors are now displayed in a library fashion.

### Changed

- Played and queuing playlist entries can be accessed in a library fashion: they use pagination now, and queuing entries can be send to the first or the last place.

## 1.8.1 - 2023-12-17

### Fixed
Expand Down
4 changes: 2 additions & 2 deletions README.md
Expand Up @@ -29,7 +29,7 @@ npm install
### Running developement server

```shell
npm start
npm run dev
```

This runs the app in the development mode.
Expand All @@ -45,7 +45,7 @@ You will also see any lint errors in the console.
npm run build
```

This builds the app for production to the `build` folder.
This builds the app for production to the `dist` folder.
It correctly bundles React in production mode and optimizes the build for the best performance.

## Development
Expand Down
30 changes: 0 additions & 30 deletions config-overrides.js

This file was deleted.

12 changes: 2 additions & 10 deletions create_archive.sh
Expand Up @@ -17,15 +17,7 @@ archive_name=dakara-client-web_$version_number.zip
echo "Creating build, please wait..."
npm run build


# Go to build directory
cd build

# Move index.html to static dir
mv index.html static

# archive the static folder
zip -r ../"$archive_name" static
# archive the dist folder
zip -r "$archive_name" dist

echo "Archive created in $archive_name"

36 changes: 36 additions & 0 deletions index.html
@@ -0,0 +1,36 @@
<!doctype html>
<html lang="en">

<head>
<meta charset="UTF-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>Dakara</title>
<meta name="description" content="Dakara web client" />

<!-- Design -->
<link rel="stylesheet"
href="https://maxst.icons8.com/vue-static/landings/line-awesome/line-awesome/1.3.0/css/line-awesome.min.css">
<link rel="stylesheet" href="https://fonts.googleapis.com/css?family=Roboto:400,100,700,300" type="text/css">

<!--Favicons-->
<link rel="apple-touch-icon" sizes="120x120" href="/favicons/apple-touch-icon.png">
<link rel="icon" type="image/png" sizes="32x32" href="/favicons/favicon-32x32.png">
<link rel="icon" type="image/png" sizes="16x16" href="/favicons/favicon-16x16.png">
<link rel="mask-icon" href="/favicons/safari-pinned-tab.svg" color="#8612a1">
<link rel="shortcut icon" href="/favicons/favicon.ico">

<meta name="apple-mobile-web-app-title" content="Dakara">
<meta name="application-name" content="Dakara">
<meta name="theme-color" content="#8612a1">

<link rel="manifest" href="/manifest.json">
<meta name="msapplication-config" content="/browserconfig.xml">
</head>

<body>
<noscript>You need to enable JavaScript to run this app.</noscript>
<div id="root"></div>
<script type="module" src="/src/main.jsx"></script>
</body>

</html>