Merge pull request #38 from barrett-ruth/feat/open-terminal-click-new-tab
feat: open terminal ctrl-click in a new tab
This commit is contained in:
commit
5dcf03af9e
4 changed files with 21 additions and 6 deletions
3
.github/workflows/aws.yaml
vendored
3
.github/workflows/aws.yaml
vendored
|
|
@ -1,8 +1,7 @@
|
||||||
name: Deploy to AWS S3
|
name: Deploy to AWS S3
|
||||||
on:
|
on:
|
||||||
push:
|
push:
|
||||||
branches:
|
branches: [main]
|
||||||
- main
|
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
deploy:
|
deploy:
|
||||||
|
|
|
||||||
4
.github/workflows/ci.yaml
vendored
4
.github/workflows/ci.yaml
vendored
|
|
@ -2,9 +2,9 @@ name: CI
|
||||||
|
|
||||||
on:
|
on:
|
||||||
pull_request:
|
pull_request:
|
||||||
|
branches: [main]
|
||||||
push:
|
push:
|
||||||
branches:
|
branches: [main]
|
||||||
- main
|
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
lint:
|
lint:
|
||||||
|
|
|
||||||
|
|
@ -11,7 +11,7 @@
|
||||||
"check": "astro check"
|
"check": "astro check"
|
||||||
},
|
},
|
||||||
"lint-staged": {
|
"lint-staged": {
|
||||||
"*.{js,ts,jsx,tsx,json,css,scss,md,astro,html}": [
|
"*.{js,ts,jsx,tsx,json,css,scss,md,astro,html,yaml,yml}": [
|
||||||
"prettier --write",
|
"prettier --write",
|
||||||
"astro check"
|
"astro check"
|
||||||
]
|
]
|
||||||
|
|
|
||||||
|
|
@ -15,7 +15,12 @@ const promptText = topic ? `barrett@ruth:~$ ${topic}` : "barrett@ruth:~$";
|
||||||
---
|
---
|
||||||
|
|
||||||
<header>
|
<header>
|
||||||
<a href="/" class="home-link" style="text-decoration: none; color: inherit">
|
<a
|
||||||
|
href="/"
|
||||||
|
id="home-link"
|
||||||
|
class="home-link"
|
||||||
|
style="text-decoration: none; color: inherit"
|
||||||
|
>
|
||||||
<div class="terminal-container">
|
<div class="terminal-container">
|
||||||
<span class="terminal-prompt">{promptText}</span>
|
<span class="terminal-prompt">{promptText}</span>
|
||||||
<span class="terminal-cursor"></span>
|
<span class="terminal-cursor"></span>
|
||||||
|
|
@ -49,4 +54,15 @@ const promptText = topic ? `barrett@ruth:~$ ${topic}` : "barrett@ruth:~$";
|
||||||
}
|
}
|
||||||
</style>
|
</style>
|
||||||
|
|
||||||
|
<script is:inline>
|
||||||
|
const homeLink = document.getElementById("home-link");
|
||||||
|
|
||||||
|
homeLink.addEventListener("click", (e) => {
|
||||||
|
if (e.ctrlKey || e.metaKey) {
|
||||||
|
e.preventDefault();
|
||||||
|
window.open("/", "_blank", "noopener");
|
||||||
|
}
|
||||||
|
});
|
||||||
|
</script>
|
||||||
|
|
||||||
<script src="/scripts/index.js" is:inline></script>
|
<script src="/scripts/index.js" is:inline></script>
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue