Skip to content

Commit

Permalink
fix: Fixed styling on "Commit selected" page (#1028)
Browse files Browse the repository at this point in the history
  • Loading branch information
JohnstonCode authored Aug 3, 2020
1 parent 9a4634a commit c63e3a3
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 2 deletions.
3 changes: 2 additions & 1 deletion src/historyView/common.ts
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,8 @@ export function transform(

export function getIconObject(iconName: string): { light: Uri; dark: Uri } {
// XXX Maybe use full path to extension?
const iconsRootPath = path.join(__dirname, "..", "..", "icons");
// Path needs to be relative from out/
const iconsRootPath = path.join(__dirname, "..", "icons");
const toUri = (theme: string) =>
Uri.file(path.join(iconsRootPath, theme, `${iconName}.svg`));
return {
Expand Down
1 change: 1 addition & 0 deletions src/resource.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ import { PropStatus, Status } from "./common/types";
import { memoize } from "./decorators";
import { configuration } from "./helpers/configuration";

// Path needs to be relative from out/
const iconsRootPath = path.join(__dirname, "..", "icons");

function getIconUri(iconName: string, theme: string): Uri {
Expand Down
1 change: 1 addition & 0 deletions src/uri.ts
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@ export function toSvnUri(
}

export function getIconUri(iconName: string, theme: string): Uri {
// Path needs to be relative from out/
const iconsRootPath = path.join(__dirname, "..", "icons");
return Uri.file(path.join(iconsRootPath, theme, `${iconName}.svg`));
}
4 changes: 3 additions & 1 deletion webpack.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,9 @@ const IGNORED = ['jschardet', 'iconv-lite', 'iconv-lite-umd', './vscodeModules']
/**@type {import('webpack').Configuration}*/
const config = {
target: 'node', // vscode extensions run in a Node.js-context 📖 -> https://webpack.js.org/configuration/node/

node: {
__dirname: false
},
entry: './src/extension.ts', // the entry point of this extension, 📖 -> https://webpack.js.org/configuration/entry-context/
output: {
// the bundle is stored in the 'dist' folder (check package.json), 📖 -> https://webpack.js.org/configuration/output/
Expand Down

0 comments on commit c63e3a3

Please sign in to comment.