@stacksjs/defaults 0.70.258 → 0.70.260

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -2,7 +2,7 @@
2
2
  "publisher": "Stacks",
3
3
  "name": "vscode-stacks",
4
4
  "displayName": "Stacks",
5
- "version": "0.70.258",
5
+ "version": "0.70.260",
6
6
  "description": "A modern Stacks development environment.",
7
7
  "license": "MIT",
8
8
  "funding": "https://github.com/sponsors/chrisbbreuer",
package/package.json CHANGED
@@ -2,7 +2,7 @@
2
2
  "name": "@stacksjs/defaults",
3
3
  "type": "module",
4
4
  "sideEffects": false,
5
- "version": "0.70.258",
5
+ "version": "0.70.260",
6
6
  "description": "The complete managed Stacks application scaffold, including runtime defaults, AI guidance, editor metadata, and npm-backed project support files.",
7
7
  "author": "Chris Breuer",
8
8
  "license": "MIT",
@@ -29,8 +29,19 @@
29
29
  "project"
30
30
  ],
31
31
  "exports": {
32
- "./*": "./*",
33
- "./package.json": "./package.json"
32
+ "./*": {
33
+ "types": "./dist/*.d.ts",
34
+ "bun": "./dist/*.js",
35
+ "import": "./dist/*.js",
36
+ "default": "./dist/*.js"
37
+ },
38
+ "./package.json": "./package.json",
39
+ "./*.js": {
40
+ "types": "./dist/*.d.ts",
41
+ "bun": "./dist/*.js",
42
+ "import": "./dist/*.js",
43
+ "default": "./dist/*.js"
44
+ }
34
45
  },
35
46
  "dependencies": {
36
47
  "@iconify-json/f7": "^1.2.2",
package/project/buddy CHANGED
@@ -53,7 +53,13 @@ run_with_timeout() {
53
53
  cmd_pid=$!
54
54
 
55
55
  (
56
- sleep "${timeout_seconds}"
56
+ # Do not let the timer inherit the deployment lock or a caller's
57
+ # stdout/stderr pipe. If the
58
+ # watchdog shell is terminated after the command finishes, its sleep may
59
+ # briefly remain orphaned; inherited deploy descriptors would otherwise
60
+ # keep the release locked until the full timeout elapsed.
61
+ exec 9>&-
62
+ sleep "${timeout_seconds}" </dev/null >/dev/null 2>&1
57
63
 
58
64
  if kill -0 "${cmd_pid}" 2>/dev/null; then
59
65
  echo "Command timed out after ${timeout_seconds}s: $*" >&2
@@ -1,3 +1,32 @@
1
+ <script server>
2
+ /**
3
+ * The providers whose buttons are worth rendering.
4
+ *
5
+ * `configuredSocialProviders()` knows each provider's own required config,
6
+ * so a provider missing credentials never reaches a visitor as a button
7
+ * that fails at the redirect. Adding credentials to `config/services.ts`
8
+ * is the whole of what turns one on.
9
+ *
10
+ * Icons come from hugeicons, the collection Stacks defaults to. Swap the
11
+ * map if your app standardises on another one.
12
+ */
13
+ import { configuredSocialProviders } from '@stacksjs/socials'
14
+
15
+ const PROVIDER_ICONS = {
16
+ apple: 'i-hugeicons-apple',
17
+ facebook: 'i-hugeicons-facebook-01',
18
+ github: 'i-hugeicons-github',
19
+ google: 'i-hugeicons-google',
20
+ twitter: 'i-hugeicons-new-twitter',
21
+ }
22
+
23
+ const socialSignIn = configuredSocialProviders().map(provider => ({
24
+ label: provider.label,
25
+ href: `/auth/${provider.name}/redirect`,
26
+ icon: PROVIDER_ICONS[provider.name] ?? 'i-hugeicons-user-circle',
27
+ }))
28
+ </script>
29
+
1
30
  <div class="flex flex-col justify-center py-12 sm:px-6 lg:px-8 min-h-full">
2
31
  <div class="sm:mx-auto sm:max-w-md sm:w-full">
3
32
  <Logo class="mx-auto h-11 w-auto" />
@@ -46,40 +75,46 @@
46
75
  </div>
47
76
  </form>
48
77
 
49
- <div>
50
- <div class="relative mt-10">
51
- <div class="flex absolute inset-0 items-center" aria-hidden="true">
52
- <div class="w-full border-gray-200 border-t"></div>
53
- </div>
54
- <div class="flex relative justify-center font-medium leading-6 text-sm">
55
- <span class="px-6 text-gray-900 bg-white">Or continue with</span>
56
- </div>
57
- </div>
78
+ {{--
79
+ Social sign-in, driven by which providers are actually configured.
58
80
 
59
- <div class="grid gap-4 grid-cols-2 mt-6">
60
- <a href="#" class="flex gap-3 items-center justify-center px-3 py-2 w-full font-semibold text-gray-900 text-sm bg-white hover:bg-gray-50 ring-1 ring-gray-300 ring-inset rounded-md focus-visible:ring-transparent shadow-sm">
61
- <svg class="h-5 w-5" viewBox="0 0 24 24" aria-hidden="true">
62
- <path d="M12.0003 4.75C13.7703 4.75 15.3553 5.36002 16.6053 6.54998L20.0303 3.125C17.9502 1.19 15.2353 0 12.0003 0C7.31028 0 3.25527 2.69 1.28027 6.60998L5.27028 9.70498C6.21525 6.86002 8.87028 4.75 12.0003 4.75Z" fill="#EA4335" />
63
- <path d="M23.49 12.275C23.49 11.49 23.415 10.73 23.3 10H12V14.51H18.47C18.18 15.99 17.34 17.25 16.08 18.1L19.945 21.1C22.2 19.01 23.49 15.92 23.49 12.275Z" fill="#4285F4" />
64
- <path d="M5.26498 14.2949C5.02498 13.5699 4.88501 12.7999 4.88501 11.9999C4.88501 11.1999 5.01998 10.4299 5.26498 9.7049L1.275 6.60986C0.46 8.22986 0 10.0599 0 11.9999C0 13.9399 0.46 15.7699 1.28 17.3899L5.26498 14.2949Z" fill="#FBBC05" />
65
- <path d="M12.0004 24.0001C15.2404 24.0001 17.9654 22.935 19.9454 21.095L16.0804 18.095C15.0054 18.82 13.6204 19.245 12.0004 19.245C8.8704 19.245 6.21537 17.135 5.2654 14.29L1.27539 17.385C3.25539 21.31 7.3104 24.0001 12.0004 24.0001Z" fill="#34A853" />
66
- </svg>
67
- <span class="font-semibold leading-6 text-sm">Google</span>
68
- </a>
81
+ This block used to be two hardcoded buttons pointing at `href="#"`,
82
+ so a scaffolded app shipped a Google and a GitHub button that both
83
+ did nothing, and offered them whether or not either provider had
84
+ credentials. `configuredSocialProviders()` answers that per
85
+ provider on each provider's own terms (Apple has no clientSecret
86
+ and is validated on its signing key instead), so what renders here
87
+ is exactly the set that will complete a sign-in.
88
+ --}}
89
+ @if (socialSignIn.length)
90
+ <div>
91
+ <div class="relative mt-10">
92
+ <div class="flex absolute inset-0 items-center" aria-hidden="true">
93
+ <div class="w-full border-gray-200 border-t"></div>
94
+ </div>
95
+ <div class="flex relative justify-center font-medium leading-6 text-sm">
96
+ <span class="px-6 text-gray-900 bg-white">Or continue with</span>
97
+ </div>
98
+ </div>
69
99
 
70
- <a href="#" class="flex gap-3 items-center justify-center px-3 py-2 w-full font-semibold text-gray-900 text-sm bg-white hover:bg-gray-50 ring-1 ring-gray-300 ring-inset rounded-md focus-visible:ring-transparent shadow-sm">
71
- <svg class="h-5 w-5 fill-[#24292F]" fill="currentColor" viewBox="0 0 20 20" aria-hidden="true">
72
- <path fill-rule="evenodd" d="M10 0C4.477 0 0 4.484 0 10.017c0 4.425 2.865 8.18 6.839 9.504.5.092.682-.217.682-.483 0-.237-.008-.868-.013-1.703-2.782.605-3.369-1.343-3.369-1.343-.454-1.158-1.11-1.466-1.11-1.466-.908-.62.069-.608.069-.608 1.003.07 1.531 1.032 1.531 1.032.892 1.53 2.341 1.088 2.91.832.092-.647.35-1.088.636-1.338-2.22-.253-4.555-1.113-4.555-4.951 0-1.093.39-1.988 1.029-2.688-.103-.253-.446-1.272.098-2.65 0 0 .84-.27 2.75 1.026A9.564 9.564 0 0110 4.844c.85.004 1.705.115 2.504.337 1.909-1.296 2.747-1.027 2.747-1.027.546 1.379.203 2.398.1 2.651.64.7 1.028 1.595 1.028 2.688 0 3.848-2.339 4.695-4.566 4.942.359.31.678.921.678 1.856 0 1.338-.012 2.419-.012 2.747 0 .268.18.58.688.482A10.019 10.019 0 0020 10.017C20 4.484 15.522 0 10 0z" clip-rule="evenodd" />
73
- </svg>
74
- <span class="font-semibold leading-6 text-sm">GitHub</span>
75
- </a>
100
+ <div class="grid gap-4 mt-6 {{ socialSignIn.length > 1 ? 'grid-cols-2' : 'grid-cols-1' }}">
101
+ @foreach (socialSignIn as provider)
102
+ <a
103
+ href="{{ provider.href }}"
104
+ class="flex gap-3 items-center justify-center px-3 py-2 w-full font-semibold text-gray-900 text-sm bg-white hover:bg-gray-50 ring-1 ring-gray-300 ring-inset rounded-md focus-visible:ring-transparent shadow-sm"
105
+ >
106
+ <i class="h-5 w-5 {{ provider.icon }}" aria-hidden="true"></i>
107
+ <span class="font-semibold leading-6 text-sm">{{ provider.label }}</span>
108
+ </a>
109
+ @endforeach
110
+ </div>
76
111
  </div>
77
- </div>
112
+ @endif
78
113
  </div>
79
114
 
80
115
  <p class="mt-10 text-center text-gray-500 text-sm">
81
116
  Already have an account?
82
- <a href="#" class="font-semibold leading-6 text-blue-600 hover:text-blue-500">Sign in</a>
117
+ <a href="/login" class="font-semibold leading-6 text-blue-600 hover:text-blue-500">Sign in</a>
83
118
  </p>
84
119
  </div>
85
120
  </div>