Skip to content

Commit

Permalink
Merge pull request #195 from daltonmenezes/feat/chrome-v2
Browse files Browse the repository at this point in the history
feat(chrome): release v2
  • Loading branch information
daltonmenezes authored Sep 25, 2023
2 parents 7ea467f + 695b96b commit d9716b1
Show file tree
Hide file tree
Showing 10 changed files with 20 additions and 25 deletions.
2 changes: 1 addition & 1 deletion packages/chrome/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@
</p>

<p align="center">
<img alt="preview" src="https://github.com/daltonmenezes/assets/blob/master/images/aura-theme/aura-chrome-preview.png?raw=true" />
<img alt="preview" src="https://github.com/daltonmenezes/aura-theme/assets/1149845/b6400889-80a0-4d63-97c9-f816a6bc24be" />
</p>

# Installation
Expand Down
Binary file modified packages/chrome/store/chrome-aura-theme.zip
Binary file not shown.
Binary file modified packages/chrome/store/preview.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified packages/chrome/store/small-tile-preview.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
1 change: 1 addition & 0 deletions src/core/colors/schemes/common.ts
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,7 @@ export const commonUI = {
accent36: '#a19c77', // debugging background
accent37: '#353424', // breakpoint frame highlight
accent38: '#29263c', // primary-selection without alpha
accent39: '#211D26',
}

export const commonSoftUI = {
Expand Down
Binary file modified src/ports/chrome/extra/store/preview.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified src/ports/chrome/extra/store/small-tile-preview.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file removed src/ports/chrome/extra/theme_tab_background.png
Binary file not shown.
34 changes: 17 additions & 17 deletions src/ports/chrome/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,28 +3,29 @@ import { resolve } from 'path'

export async function ChromePort(Aura: AuraAPI) {
const {
copyExtraFiles,
zip,
unlink,
constants,
createPort,
createReadme,
colorSchemes,
colorHandlers,
constants,
zip,
unlink,
copyExtraFiles,
} = Aura

const { info } = constants
const { info, isProd } = constants

const portName = 'Google Chrome'
const version = '1.0.2'
const version = '2.0.0'
const extensionID = 'ddipnaombfnagpagnpdkdinoekfhfjoh'
const previewURL = `https://github.com/${info.author.username}/assets/blob/master/images/${info.slug}/aura-chrome-preview.png?raw=true`
const templateFolder = resolve(__dirname, 'templates')
const previewURL = `https://github.com/${info.author.username}/${info.slug}/assets/1149845/b6400889-80a0-4d63-97c9-f816a6bc24be`

await copyExtraFiles(__dirname)

await createPort({
template: resolve(templateFolder, 'manifest.json'),

replacements: {
...colorHandlers.schemeToRgb(colorSchemes.dark),
...info,
Expand All @@ -34,25 +35,24 @@ export async function ChromePort(Aura: AuraAPI) {

await createReadme({
template: resolve(templateFolder, 'README.md'),

replacements: {
portName,
extensionID,
previewURL,
extensionID,
},
})

const chromePackagePath = resolve('packages', 'chrome')
const manifestFile = resolve(chromePackagePath, 'manifest.json')

const backgroundFile = resolve(
chromePackagePath,
'theme_tab_background.png'
)
if (isProd) {
zip.addFile(manifestFile)

zip.addFile(manifestFile)
zip.addFile(backgroundFile)
zip.writeZip(resolve(chromePackagePath, 'store', 'chrome-aura-theme.zip'))
zip.writeZip(
resolve(chromePackagePath, 'store', 'chrome-aura-theme.zip')
)

await unlink(manifestFile)
await unlink(backgroundFile)
await unlink(manifestFile)
}
}
8 changes: 1 addition & 7 deletions src/ports/chrome/templates/manifest.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
"colors" : {
"frame": [{{ accent12 }}],
"frame_inactive": [{{ accent30 }}],
"toolbar": [{{ accent12 }}],
"toolbar": [{{ accent39 }}],
"toolbar_button_icon": [{{ accent2 }}],
"ntp_background": [{{ accent12 }}],
"ntp_text": [{{ accent7 }}],
Expand All @@ -20,12 +20,6 @@
},
"tints" : {
"buttons" : [0.33, 0.5, 0.47]
},
"properties" : {
"ntp_background_alignment" : "bottom"
},
"images" : {
"theme_toolbar": "theme_tab_background.png"
}
}
}

0 comments on commit d9716b1

Please sign in to comment.