Skip to content

Commit

Permalink
ci: update file icons (#2157)
Browse files Browse the repository at this point in the history
Co-authored-by: delucis <357379+delucis@users.noreply.github.com>
Co-authored-by: Chris Swithinbank <swithinbank@gmail.com>
  • Loading branch information
3 people authored Jul 28, 2024
1 parent 85b1ab4 commit 6757d97
Show file tree
Hide file tree
Showing 2 changed files with 22 additions and 0 deletions.
5 changes: 5 additions & 0 deletions .changeset/sharp-onions-search.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@astrojs/starlight": patch
---

Updates file tree icon mapping to correctly map `.cjs` and `.mjs` extensions in several contexts
17 changes: 17 additions & 0 deletions packages/starlight/user-components/file-tree-icons.ts
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,8 @@ export const definitions: Definitions = {
COMMIT_EDITMSG: 'seti:git',
MERGE_MSG: 'seti:git',
'karma.conf.js': 'seti:karma',
'karma.conf.cjs': 'seti:karma',
'karma.conf.mjs': 'seti:karma',
'karma.conf.coffee': 'seti:karma',
'README.md': 'seti:info',
'README.txt': 'seti:info',
Expand Down Expand Up @@ -74,6 +76,7 @@ export const definitions: Definitions = {
'WORKSPACE.bazel': 'seti:bazel',
'bower.json': 'seti:bower',
'Bower.json': 'seti:bower',
'eslint.config.js': 'seti:eslint',
'firebase.json': 'seti:firebase',
geckodriver: 'seti:firefox',
'Gruntfile.js': 'seti:grunt',
Expand All @@ -91,22 +94,28 @@ export const definitions: Definitions = {
'sass-lint.yml': 'seti:sass',
'stylelint.config.js': 'seti:stylelint',
'stylelint.config.cjs': 'seti:stylelint',
'stylelint.config.mjs': 'seti:stylelint',
'yarn.clean': 'seti:yarn',
'yarn.lock': 'seti:yarn',
'webpack.config.js': 'seti:webpack',
'webpack.config.cjs': 'seti:webpack',
'webpack.config.mjs': 'seti:webpack',
'webpack.config.ts': 'seti:webpack',
'webpack.config.build.js': 'seti:webpack',
'webpack.config.build.cjs': 'seti:webpack',
'webpack.config.build.mjs': 'seti:webpack',
'webpack.config.build.ts': 'seti:webpack',
'webpack.common.js': 'seti:webpack',
'webpack.common.cjs': 'seti:webpack',
'webpack.common.mjs': 'seti:webpack',
'webpack.common.ts': 'seti:webpack',
'webpack.dev.js': 'seti:webpack',
'webpack.dev.cjs': 'seti:webpack',
'webpack.dev.mjs': 'seti:webpack',
'webpack.dev.ts': 'seti:webpack',
'webpack.prod.js': 'seti:webpack',
'webpack.prod.cjs': 'seti:webpack',
'webpack.prod.mjs': 'seti:webpack',
'webpack.prod.ts': 'seti:webpack',
'npm-debug.log': 'seti:npm_ignored',
},
Expand Down Expand Up @@ -218,8 +227,16 @@ export const definitions: Definitions = {
'.properties': 'seti:java',
'.js': 'seti:javascript',
'.js.map': 'seti:javascript',
'.cjs': 'seti:javascript',
'.cjs.map': 'seti:javascript',
'.mjs': 'seti:javascript',
'.mjs.map': 'seti:javascript',
'.spec.js': 'seti:javascript',
'.spec.cjs': 'seti:javascript',
'.spec.mjs': 'seti:javascript',
'.test.js': 'seti:javascript',
'.test.cjs': 'seti:javascript',
'.test.mjs': 'seti:javascript',
'.es': 'seti:javascript',
'.es5': 'seti:javascript',
'.es6': 'seti:javascript',
Expand Down

0 comments on commit 6757d97

Please sign in to comment.