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

(#415)(#416)(#417)(#418) choco-theme 0.8.1 #420

Merged
merged 6 commits into from
Oct 2, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
65 changes: 0 additions & 65 deletions .eslintrc.js

This file was deleted.

2 changes: 1 addition & 1 deletion .github/workflows/audit.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -10,5 +10,5 @@ jobs:
node-version: 20
- run: yarn install --immutable
- name: Run yarn npm audit
run: yarn npm audit --severity moderate
run: yarn npm audit --all --recursive --ignore 1094698
continue-on-error: false
1 change: 1 addition & 0 deletions .vscode/settings.json
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,7 @@
"stylelint",
"stylelintcache",
"svgstyles",
"sweetalert",
"tarekraafat",
"textbox",
"topnav",
Expand Down
41 changes: 31 additions & 10 deletions CREDITS.md
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,7 @@ limitations under the License.

```

#### [@playwright/[email protected].0](https://github.com/microsoft/playwright)
#### [@playwright/[email protected].2](https://github.com/microsoft/playwright)

[Repository Link](https://github.com/microsoft/playwright)

Expand Down Expand Up @@ -690,6 +690,20 @@ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLI
No additional license information is available for this package.
Refer to the license text above, listed under [MIT License](#mit-license).

#### [@eslint/[email protected]](https://github.com/eslint/eslintrc)

[Repository Link](https://github.com/eslint/eslintrc)

No additional license information is available for this package.
Refer to the license text above, listed under [MIT License](#mit-license).

#### [@eslint/[email protected]](https://github.com/eslint/eslint)

[Repository Link](https://github.com/eslint/eslint)

No additional license information is available for this package.
Refer to the license text above, listed under [MIT License](#mit-license).

#### [@microsoft/[email protected]](https://github.com/dotnet/aspnetcore)

[Repository Link](https://github.com/dotnet/aspnetcore)
Expand All @@ -711,7 +725,7 @@ Refer to the license text above, listed under [MIT License](#mit-license).
No additional license information is available for this package.
Refer to the license text above, listed under [MIT License](#mit-license).

#### [@types/[email protected].5](https://github.com/DefinitelyTyped/DefinitelyTyped)
#### [@types/[email protected].10](https://github.com/DefinitelyTyped/DefinitelyTyped)

[Repository Link](https://github.com/DefinitelyTyped/DefinitelyTyped)

Expand All @@ -725,7 +739,7 @@ Refer to the license text above, listed under [MIT License](#mit-license).
No additional license information is available for this package.
Refer to the license text above, listed under [MIT License](#mit-license).

#### [[email protected].2](https://github.com/aspnetboilerplate/bower-abp-resources)
#### [[email protected].3](https://github.com/aspnetboilerplate/bower-abp-resources)

[Repository Link](https://github.com/aspnetboilerplate/bower-abp-resources)

Expand Down Expand Up @@ -767,14 +781,14 @@ Refer to the license text above, listed under [MIT License](#mit-license).
No additional license information is available for this package.
Refer to the license text above, listed under [MIT License](#mit-license).

#### [[email protected].6](https://github.com/DataTables/Dist-DataTables-Bootstrap5)
#### [[email protected].7](https://github.com/DataTables/Dist-DataTables-Bootstrap5)

[Repository Link](https://github.com/DataTables/Dist-DataTables-Bootstrap5)

No additional license information is available for this package.
Refer to the license text above, listed under [MIT License](#mit-license).

#### [[email protected].6](https://github.com/DataTables/Dist-DataTables-DataTables)
#### [[email protected].7](https://github.com/DataTables/Dist-DataTables-DataTables)

[Repository Link](https://github.com/DataTables/Dist-DataTables-DataTables)

Expand All @@ -788,7 +802,7 @@ Refer to the license text above, listed under [MIT License](#mit-license).
No additional license information is available for this package.
Refer to the license text above, listed under [MIT License](#mit-license).

#### [eslint@8.57.0](https://github.com/eslint/eslint)
#### [eslint@9.11.1](https://github.com/eslint/eslint)

[Repository Link](https://github.com/eslint/eslint)

Expand Down Expand Up @@ -830,6 +844,13 @@ Refer to the license text above, listed under [MIT License](#mit-license).
No additional license information is available for this package.
Refer to the license text above, listed under [MIT License](#mit-license).

#### [[email protected]](https://github.com/sindresorhus/globals)

[Repository Link](https://github.com/sindresorhus/globals)

No additional license information is available for this package.
Refer to the license text above, listed under [MIT License](#mit-license).

#### [[email protected]](https://github.com/jquery/jquery)

[Repository Link](https://github.com/jquery/jquery)
Expand Down Expand Up @@ -893,14 +914,14 @@ Refer to the license text above, listed under [MIT License](#mit-license).
No additional license information is available for this package.
Refer to the license text above, listed under [MIT License](#mit-license).

#### [[email protected].2](https://github.com/bcomnes/npm-run-all2)
#### [[email protected].3](https://github.com/bcomnes/npm-run-all2)

[Repository Link](https://github.com/bcomnes/npm-run-all2)

No additional license information is available for this package.
Refer to the license text above, listed under [MIT License](#mit-license).

#### [[email protected].45](https://github.com/postcss/postcss)
#### [[email protected].47](https://github.com/postcss/postcss)

[Repository Link](https://github.com/postcss/postcss)

Expand All @@ -914,7 +935,7 @@ Refer to the license text above, listed under [MIT License](#mit-license).
No additional license information is available for this package.
Refer to the license text above, listed under [MIT License](#mit-license).

#### [purgecss@5.0.0](https://github.com/FullHuman/purgecss)
#### [purgecss@6.0.0](https://github.com/FullHuman/purgecss)

[Repository Link](https://github.com/FullHuman/purgecss)

Expand Down Expand Up @@ -963,7 +984,7 @@ Refer to the license text above, listed under [MIT License](#mit-license).
No additional license information is available for this package.
Refer to the license text above, listed under [MIT License](#mit-license).

#### [[email protected].0](https://github.com/sweetalert2/sweetalert2)
#### [[email protected].1](https://github.com/sweetalert2/sweetalert2)

[Repository Link](https://github.com/sweetalert2/sweetalert2)

Expand Down
29 changes: 15 additions & 14 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Chocolatey choco-theme 0.8.0
# Chocolatey choco-theme 0.8.1

**NOTE: This project is used on Chocolatey websites and is being released for the benefit of the community. While we endeavour to help and fix issues, it will be limited to GitHub issues, discussions and pull requests when we are able to.**

Expand All @@ -8,19 +8,20 @@ This repository holds all of the CSS, JS, images, and shared partial files that

Before running any commands below, ensure you have ran `yarn` in the root of this repository, and have enabled corepack by running `corepack enable`.

| Script | Action |
|-------------------------------------------------|-----------------------------------------------------------------------------------------------|
| yarn build | Builds CSS, JS, and Partials. |
| yarn change-version OLD_VERSION NEW_VERSION | Runs all build steps and updates choco-theme to the version specified. |
| yarn lint | Runs Stylelint and ESLint to determine code style errors. |
| yarn monitor-ports | Opens a page to monitor preview ports and report their status. |
| yarn npm audit | Audits packages and reports vulnerabilities. |
| yarn preview --PROJECT_NAME | Runs the preview script in desired repositories all at once for easy testing and development. |
| yarn preview-link --PROJECT_NAME | Links choco-theme locally to desired repositories for local development. |
| yarn preview-unlink --PROJECT_NAME | Unlinks choco-theme and restores the packages.json and yarn.lock files. |
| yarn preview-upgrade NEW_VERSION --PROJECT_NAME | Updates choco-theme to the specified version in desired repositories. |
| yarn preview-watch --PROJECT_NAME | Runs `yarn build` and `yarn-choco-theme` on desired repositories. |
| yarn watch | Watches for changes in CSS, JS, and Partials, and rebuilds them automatically. |
| Script | Action |
|---------------------------------------------------|-----------------------------------------------------------------------------------------------|
| yarn npm audit --all --recursive --ignore 1094698 | Audits all dependencies recursively and ignores [sweetalert2 vulnerability](https://github.com/advisories/GHSA-mrr8-v49w-3333). |
| yarn build | Builds CSS, JS, and Partials. |
| yarn change-version OLD_VERSION NEW_VERSION | Runs all build steps and updates choco-theme to the version specified. |
| yarn lint | Runs Stylelint and ESLint to determine code style errors. |
| yarn monitor-ports | Opens a page to monitor preview ports and report their status. |
| yarn npm audit | Audits packages and reports vulnerabilities. |
| yarn preview --PROJECT_NAME | Runs the preview script in desired repositories all at once for easy testing and development. |
| yarn preview-link --PROJECT_NAME | Links choco-theme locally to desired repositories for local development. |
| yarn preview-unlink --PROJECT_NAME | Unlinks choco-theme and restores the packages.json and yarn.lock files. |
| yarn preview-upgrade NEW_VERSION --PROJECT_NAME | Updates choco-theme to the specified version in desired repositories. |
| yarn preview-watch --PROJECT_NAME | Runs `yarn build` and `yarn-choco-theme` on desired repositories. |
| yarn watch | Watches for changes in CSS, JS, and Partials, and rebuilds them automatically. |

## Repository Project Names for Previewing

Expand Down
22 changes: 11 additions & 11 deletions build/choco-theme.ts
Original file line number Diff line number Diff line change
Expand Up @@ -61,12 +61,6 @@ const init = async () => {
source: `${repositoryConfig.theme.css}${sourceCss}.min.css`,
destination: `${repository.css}${repository.name}.min.css`,
isFolder: false
},
{
task: 'PT Sans',
source: repositoryConfig.theme.ptSans,
destination: repository.ptSans,
isFolder: true
}
];

Expand Down Expand Up @@ -231,14 +225,20 @@ const init = async () => {
);
}

// Font Awesome
// Font Awesome and PT Sans
if (repository.name !== repositoryConfig.zendesk.name) {
parallelTasksInitial.push(
{
task: 'Font Awesome',
source: repositoryConfig.theme.fontAwesome,
destination: repository.fontAwesome,
isFolder: true
},
{
task: 'PT Sans',
source: repositoryConfig.theme.ptSans,
destination: repository.ptSans,
isFolder: true
}
);
}
Expand All @@ -255,13 +255,13 @@ const init = async () => {
);
}

// ESLint and tsconfig - needed if repository contains it's own assets along with choco-theme
// ESLint - needed if repository contains it's own assets along with choco-theme
if (repository.name === repositoryConfig.portal.name || repository.name === repositoryConfig.ccm.name) {
parallelTasksInitial.push(
{
task: '.eslintrc.js',
source: `${repositoryConfig.theme.root}.eslintrc.js`,
destination: `${repository.root}.eslintrc.js`,
task: 'eslint.config.mjs',
source: `${repositoryConfig.theme.root}eslint.config.mjs`,
destination: `${repository.root}eslint.config.mjs`,
isFolder: false
}
);
Expand Down
6 changes: 4 additions & 2 deletions build/data/repository-config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ export const astroRepositoryConfig = {
js: 'public/scripts/',
favicons: 'public/',
fontAwesome: 'public/fonts/fontawesome-free/',
ptSans: 'public/fonts/fonts/PT_Sans/',
ptSans: 'public/fonts/PT_Sans/',
images: 'public/images/global-shared/',
partials: 'src/components/global/',
language: 'astro',
Expand Down Expand Up @@ -169,7 +169,6 @@ export const repositoryConfig: Record<string, RepositoryConfig> = {
css: 'assets/',
js: 'assets/',
favicons: 'assets/',
ptSans: 'assets/fonts/PT_Sans/',
partials: 'global-partials/',
language: 'hbs'
}
Expand Down Expand Up @@ -270,6 +269,9 @@ repositoryConfig.zendesk.purgeCss = {
],
safelist: [
...defaultRepositoryConfig.purgeCss.safelist,
/^fa-(check|triangle-exclamation|info|xmark)/,
/^bg-(secondary|danger|success)/,
/^callout-(danger|success)/,
'main',
'table-bordered',
'table-striped',
Expand Down
2 changes: 1 addition & 1 deletion build/esbuild.ts
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ const init = async () => {
const minify = process.argv.includes('--minify');

const banner: string = `/*!
* choco-theme v0.8.0 (https://github.com/chocolatey/choco-theme#readme)
* choco-theme v0.8.1 (https://github.com/chocolatey/choco-theme#readme)
* Copyright 2020-2024 Chocolatey Software
* Licensed under MIT (https://github.com/chocolatey/choco-theme/blob/main/LICENSE)
*/`;
Expand Down
2 changes: 1 addition & 1 deletion build/preview-choco-theme.ts
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ const init = async () => {
// Handle stdout data event
childProcess.stdout.on('data', data => {
const output = data.toString().trim();
if (output.includes('🎉 choco-theme complete' || output.startsWith('[nodemon] restarting due to changes...'))) {
if (output.includes('🎉 choco-theme complete') || output.startsWith('[nodemon] restarting due to changes...')) {
// Stop loading animation for this script
clearInterval(loadingIntervals[index]);
process.stdout.write('\r✅ ');
Expand Down
5 changes: 5 additions & 0 deletions build/preview.ts
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,11 @@ const init = async () => {
const folderPath = path.join(__dirname, '../../', folderName);
const port = folderConfig.port;

if (isWindows && !folderIsAstro) {
console.log(`⛔ This script does not currently run on Windows for ${folderName}.`);
clearInterval(loadingIntervals[index]);
}

if (folderIsAstro) {
const childProcessTwo = spawn('yarn dev', [], {
shell: true,
Expand Down
14 changes: 12 additions & 2 deletions dist/css/atcb-overrides.css
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
*
* Style: Default
*
* Version: 2.6.19
* Version: 2.6.21
* Creator: Jens Kuerschner (https://jekuer.com)
* Project: https://github.com/add2cal/add-to-calendar-button
* License: Elastic License 2.0 (ELv2) (https://github.com/add2cal/add-to-calendar-button/blob/main/LICENSE.txt)
Expand Down Expand Up @@ -1339,6 +1339,7 @@ a.atcb-modal-btn:not([disabled]):hover {
filter: drop-shadow(0 0 3px rgba(255 255 255/80%));
height: auto;
padding: 8px 0;
text-align: center;
transform: translate3d(0, 0, 0);
width: 100%;
z-index: 15000000;
Expand All @@ -1355,6 +1356,10 @@ a.atcb-modal-btn:not([disabled]):hover {
position: absolute;
}

.atcb-modal-host-initialized #atcb-reference.atcb-dropup {
text-align: left;
}

/* :host-context(html.atcb-dark):host(.atcb-bodyScheme) #atcb-reference,
:host-context(body.atcb-dark):host(.atcb-bodyScheme) #atcb-reference, */
:host(.atcb-dark) #atcb-reference {
Expand All @@ -1368,7 +1373,7 @@ a.atcb-modal-btn:not([disabled]):hover {
width: 150px;
max-width: 100%;
margin: auto;
display: block;
display: inline-block;
text-decoration: none;
}

Expand Down Expand Up @@ -1421,3 +1426,8 @@ a.atcb-modal-btn:not([disabled]):hover {
.atcb-button:not([disabled]):focus, .atcb-button:not([disabled]):hover, .atcb-button.atcb-active:not(.atcb-modal-style):not(.atcb-dropoverlay):focus, .atcb-button.atcb-active:not(.atcb-modal-style):not(.atcb-dropoverlay):hover {
padding: var(--btn-padding-y) var(--btn-padding-x) !important;
}

/* stylelint-disable-next-line selector-id-pattern */
#atcb-reference {
display: none !important;
}
Loading
Loading