Skip to content

Commit 662ba9b

Browse files
authored
Merge branch 'main' into feat/og-image-v7
2 parents 499fc7e + 0164064 commit 662ba9b

File tree

18 files changed

+329
-63
lines changed

18 files changed

+329
-63
lines changed
Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
name: dependency-diff-comment
2+
3+
on:
4+
workflow_run:
5+
workflows: ['dependency-diff']
6+
types:
7+
- completed
8+
9+
permissions:
10+
pull-requests: write
11+
actions: read
12+
13+
jobs:
14+
dependency-diff-comment:
15+
name: 💬 Dependency diff comment
16+
runs-on: ubuntu-slim
17+
if: github.event.workflow_run.conclusion == 'success'
18+
19+
steps:
20+
- name: 📥 Download artifact
21+
uses: actions/download-artifact@d3f86a106a0bac45b974a628896c90dbdf5c8093 # v4.3.0
22+
with:
23+
name: e18e-diff-result
24+
run-id: ${{ github.event.workflow_run.id }}
25+
github-token: ${{ secrets.GITHUB_TOKEN }}
26+
27+
- name: 💬 Post comment
28+
uses: e18e/action-dependency-diff@f825d5b5c5ce0a42dc46c47ec20de24460affcd8 # v1.5.0
29+
with:
30+
mode: comment-from-artifact
31+
artifact-path: e18e-diff-result.json
Lines changed: 47 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,47 @@
1+
name: dependency-diff
2+
3+
on:
4+
pull_request:
5+
branches:
6+
- main
7+
- release
8+
paths:
9+
- package.json
10+
- pnpm-lock.yaml
11+
- pnpm-workspace.yaml
12+
- docs/package.json
13+
- cli/package.json
14+
15+
concurrency:
16+
group: ${{ github.workflow }}-${{ github.event.number || github.sha }}
17+
cancel-in-progress: true
18+
19+
permissions:
20+
contents: read
21+
22+
jobs:
23+
dependency-diff:
24+
name: 🔎 Dependency diff
25+
runs-on: ubuntu-slim
26+
27+
steps:
28+
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
29+
with:
30+
fetch-depth: 0
31+
32+
- name: 🔎 Compare dependencies
33+
id: analyze
34+
uses: e18e/action-dependency-diff@f825d5b5c5ce0a42dc46c47ec20de24460affcd8 # v1.5.0
35+
with:
36+
mode: artifact
37+
detect-replacements: 'true'
38+
duplicate-threshold: '4'
39+
dependency-threshold: '15'
40+
size-threshold: '200000'
41+
42+
- name: 📤 Upload artifact
43+
if: steps.analyze.outputs.artifact-path
44+
uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 # v4.6.2
45+
with:
46+
name: e18e-diff-result
47+
path: ${{ steps.analyze.outputs.artifact-path }}

.github/workflows/welcome-close.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ jobs:
3939
const body = [
4040
`Thanks for your first contribution, @${author}! ${emoji}`,
4141
'',
42-
`We'd love to welcome you to the npmx community. Come and say hi on [Discord](https://chat.npmx.dev)! And once you've joined, visit [npmx.wamellow.com](https://npmx.wamellow.com/) to claim the **contributor** role.`,
42+
`We'd love to welcome you to the npmx community. Come and say hi on [Discord](https://build.npmx.dev)! And once you've joined, visit [npmx.wamellow.com](https://npmx.wamellow.com/) to claim the **contributor** role.`,
4343
].join('\n');
4444
4545
await github.rest.issues.createComment({

app/components/CommandPalette.client.vue

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -324,6 +324,7 @@ useEventListener(document, 'keydown', handleGlobalKeydown)
324324
type="text"
325325
:placeholder="viewMeta.placeholder"
326326
no-correct
327+
no-password-manager
327328
size="lg"
328329
class="w-full"
329330
:aria-describedby="inputDescribedBy"

app/components/Input/Base.vue

Lines changed: 13 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
<script setup lang="ts">
2-
import { noCorrect } from '~/utils/input'
2+
import { noCorrect, noPasswordManager } from '~/utils/input'
33
44
const model = defineModel<string>({ default: '' })
55
@@ -16,6 +16,12 @@ const props = withDefaults(
1616
noCorrect?: boolean
1717
/** Keyboard shortcut hint */
1818
ariaKeyshortcuts?: string
19+
/**
20+
* Prevents most common password managers from recognizing the input as a password field.
21+
* Note: This is not a standard HTML attribute but vendor-specific data-* attributes.
22+
* @default false
23+
*/
24+
noPasswordManager?: boolean
1925
}>(),
2026
{
2127
size: 'md',
@@ -36,13 +42,18 @@ defineExpose({
3642
focus: () => el.value?.focus(),
3743
blur: () => el.value?.blur(),
3844
})
45+
46+
const inputAttrs = computed(() => ({
47+
...(props.noCorrect ? noCorrect : {}),
48+
...(props.noPasswordManager ? noPasswordManager : {}),
49+
}))
3950
</script>
4051

4152
<template>
4253
<input
4354
ref="el"
4455
v-model="model"
45-
v-bind="props.noCorrect ? noCorrect : undefined"
56+
v-bind="inputAttrs"
4657
@focus="emit('focus', $event)"
4758
@blur="emit('blur', $event)"
4859
class="appearance-none bg-bg-subtle border border-border font-mono text-fg placeholder:text-fg-subtle transition-[border-color,outline-color] duration-300 hover:border-fg-subtle outline-2 outline-transparent outline-offset-2 focus:border-accent focus-visible:outline-accent/70 disabled:(opacity-50 cursor-not-allowed)"

app/components/Package/ManagerSelect.vue

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -191,7 +191,8 @@ function handleKeydown(event: KeyboardEvent) {
191191
:root[data-pm='yarn'] [data-pm-select='yarn'],
192192
:root[data-pm='bun'] [data-pm-select='bun'],
193193
:root[data-pm='deno'] [data-pm-select='deno'],
194-
:root[data-pm='vlt'] [data-pm-select='vlt'] {
194+
:root[data-pm='vlt'] [data-pm-select='vlt'],
195+
:root[data-pm='vp'] [data-pm-select='vp'] {
195196
display: inline-block;
196197
}
197198

app/components/Terminal/Execute.vue

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -94,7 +94,8 @@ const copyExecuteCommand = () => copyExecute(getFullExecuteCommand())
9494
:root[data-pm='yarn'] [data-pm-cmd='yarn'],
9595
:root[data-pm='bun'] [data-pm-cmd='bun'],
9696
:root[data-pm='deno'] [data-pm-cmd='deno'],
97-
:root[data-pm='vlt'] [data-pm-cmd='vlt'] {
97+
:root[data-pm='vlt'] [data-pm-cmd='vlt'],
98+
:root[data-pm='vp'] [data-pm-cmd='vp'] {
9899
display: flex;
99100
}
100101

app/components/Terminal/Install.vue

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -412,7 +412,8 @@ useCommandPaletteContextCommands(
412412
:root[data-pm='yarn'] [data-pm-cmd='yarn'],
413413
:root[data-pm='bun'] [data-pm-cmd='bun'],
414414
:root[data-pm='deno'] [data-pm-cmd='deno'],
415-
:root[data-pm='vlt'] [data-pm-cmd='vlt'] {
415+
:root[data-pm='vlt'] [data-pm-cmd='vlt'],
416+
:root[data-pm='vp'] [data-pm-cmd='vp'] {
416417
display: flex;
417418
}
418419

app/utils/input.ts

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,3 +28,15 @@ export function isKeyWithoutModifiers(event: KeyboardEvent, key: string): boolea
2828
}
2929

3030
export const DATE_INPUT_MAX = '9999-12-31'
31+
32+
/** Attributes to prevent password managers from recognizing an input as a password field. */
33+
export const noPasswordManager = {
34+
/* ProtonPass, https://stackoverflow.com/a/51272839 */
35+
['data-protonpass-ignore']: 'true',
36+
/* LastPass, https://stackoverflow.com/a/51272839 */
37+
['data-lpignore']: 'true',
38+
/* 1Password, https://stackoverflow.com/a/51272839 */
39+
['data-1p-ignore']: 'true',
40+
/* Bitwarden, https://stackoverflow.com/questions/41945535/html-disable-password-manager#comment139327111_51272839 */
41+
['data-bwignore']: 'true',
42+
} as const

app/utils/install-command.ts

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -59,6 +59,15 @@ export const packageManagers = [
5959
create: 'vlx',
6060
icon: 'i-custom-vlt',
6161
},
62+
{
63+
id: 'vp',
64+
label: 'vp',
65+
action: 'add',
66+
executeLocal: 'vp exec',
67+
executeRemote: 'vp dlx',
68+
create: 'vp create',
69+
icon: 'i-simple-icons:vite',
70+
},
6271
] as const
6372

6473
export type PackageManagerId = (typeof packageManagers)[number]['id']

0 commit comments

Comments
 (0)