Skip to content

Commit

Permalink
Merge pull request #6 from vuesence/test/no-ref/add-more-options
Browse files Browse the repository at this point in the history
chore: refactor app options
  • Loading branch information
altrusl authored Jan 31, 2024
2 parents 653bac0 + a1eaed9 commit 77c4d4b
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 7 deletions.
4 changes: 1 addition & 3 deletions src/App.vue
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ import { DefaultOptions as options } from "./options";
// import "./style.css";
// import "release-timeline/dist/animated-background.css";
import "./animated-background.css";
const key = ref(0);
Expand All @@ -15,10 +16,7 @@ options.github.repo = "release-timeline";
function changeRepo() {
const url = prompt("Please enter Github Repo url", "https://github.com/vitejs/vite.git");
console.log(url);
const pathParts = url.split("/").filter(part => part); // Remove empty parts
// console.log(pathParts);
options.github.owner = pathParts[2];
options.github.repo = pathParts[3].substring(0, pathParts[3].length - 4);
key.value++;
Expand Down
4 changes: 2 additions & 2 deletions src/TimelineItemIssues.vue
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ function toggle(_tab: string) {
<span>
#{{ pull.number }}: {{ pull.title }}
</span>
<span v-if="options.display.release.pullsUsername"> - @{{ pull.author }}</span>
<span v-if="!options.display.release.hidePullUsername"> - @{{ pull.author }}</span>
</p>
</a>
</div>
Expand All @@ -80,7 +80,7 @@ function toggle(_tab: string) {
<!-- <p>{{ commit.title }} - @{{ commit.author }}</p> -->
<p>
<span>{{ commit.title }}</span>
<span v-if="options.display.release.commitsUsername"> - @{{ commit.author }}</span>
<span v-if="!options.display.release.hideCommitUsername"> - @{{ commit.author }}</span>
</p>
</a>
</div>
Expand Down
4 changes: 2 additions & 2 deletions src/options.ts
Original file line number Diff line number Diff line change
Expand Up @@ -37,8 +37,8 @@ export const DefaultOptions = {
desc: true,
pulls: true,
commits: true,
pullsUsername: true,
commitsUsername: false,
hidePullUsername: true,
hideCommitUsername: false,
hideMergeCommits: true,
// defaultOpenTab: "pulls",
},
Expand Down

0 comments on commit 77c4d4b

Please sign in to comment.