@knowcode/doc-builder 1.8.0 → 1.8.2
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.
- package/.claude/settings.local.json +4 -1
- package/CHANGELOG.md +24 -0
- package/assets/js/main.js +10 -6
- package/html/README.html +43 -5
- package/html/auth.js +61 -12
- package/html/documentation-index.html +43 -5
- package/html/guides/authentication-default-change.html +43 -5
- package/html/guides/authentication-guide.html +50 -9
- package/html/guides/claude-workflow-guide.html +43 -5
- package/html/guides/documentation-standards.html +43 -5
- package/html/guides/phosphor-icons-guide.html +43 -5
- package/html/guides/private-directory-authentication.html +246 -119
- package/html/guides/public-site-deployment.html +43 -5
- package/html/guides/search-engine-verification-guide.html +43 -5
- package/html/guides/seo-guide.html +43 -5
- package/html/guides/seo-optimization-guide.html +43 -5
- package/html/guides/troubleshooting-guide.html +43 -5
- package/html/guides/windows-setup-guide.html +43 -5
- package/html/index.html +43 -5
- package/html/js/auth.js +118 -39
- package/html/js/main.js +10 -6
- package/html/login.html +3 -3
- package/html/logout.html +2 -2
- package/html/private/cache-control-anti-pattern.html +67 -5
- package/html/private/launch/README.html +67 -5
- package/html/private/launch/auth-cleanup-summary.html +67 -5
- package/html/private/launch/bubble-plugin-specification.html +67 -5
- package/html/private/launch/go-to-market-strategy.html +67 -5
- package/html/private/launch/launch-announcements.html +67 -5
- package/html/private/launch/vercel-deployment-auth-setup.html +67 -5
- package/html/private/next-steps-walkthrough.html +67 -5
- package/html/private/supabase-auth-implementation-completed.html +67 -5
- package/html/private/supabase-auth-implementation-plan.html +67 -5
- package/html/private/supabase-auth-integration-plan.html +67 -5
- package/html/private/supabase-auth-setup-guide.html +67 -5
- package/html/private/test-private-doc.html +67 -5
- package/html/private/user-management-tooling.html +587 -0
- package/html/robots.txt +4 -0
- package/html/sitemap.xml +49 -43
- package/html/vercel-cli-setup-guide.html +43 -5
- package/html/vercel-first-time-setup-guide.html +43 -5
- package/lib/config.js +20 -27
- package/lib/core-builder.js +9 -1
- package/lib/shared-auth-config.js +21 -0
- package/lib/supabase-auth.js +20 -14
- package/package.json +1 -1
- package/user-management/README.md +280 -51
- package/user-management/add-users.sh +661 -262
- package/user-management/create-user.js +65 -0
package/CHANGELOG.md
CHANGED
|
@@ -5,6 +5,30 @@ All notable changes to @knowcode/doc-builder will be documented in this file.
|
|
|
5
5
|
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
|
|
6
6
|
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
|
|
7
7
|
|
|
8
|
+
## [1.8.2] - 2025-07-26
|
|
9
|
+
|
|
10
|
+
### Added
|
|
11
|
+
- **Automatic Supabase Credentials**: No more placeholder errors! Credentials are now built into the package
|
|
12
|
+
- **Auto-generated Site IDs**: Each site gets a unique ID automatically when authentication is enabled
|
|
13
|
+
- Shared authentication database across all doc-builder sites for easier management
|
|
14
|
+
|
|
15
|
+
### Changed
|
|
16
|
+
- Supabase URL and anonymous key are now provided by default via `shared-auth-config.js`
|
|
17
|
+
- Site IDs are auto-generated using site name, timestamp, and random string
|
|
18
|
+
- Updated documentation to reflect zero-configuration authentication
|
|
19
|
+
|
|
20
|
+
### Developer Experience
|
|
21
|
+
- No need to configure Supabase credentials manually anymore
|
|
22
|
+
- Just create a `private` directory and authentication works immediately
|
|
23
|
+
- Site administrators only need to add the auto-generated site ID to the database
|
|
24
|
+
|
|
25
|
+
## [1.8.1] - 2025-07-26
|
|
26
|
+
|
|
27
|
+
### Fixed
|
|
28
|
+
- Private directory now **always** enables authentication, even when config explicitly sets `authentication: false`
|
|
29
|
+
- This is a security enhancement to ensure private content is never accidentally exposed
|
|
30
|
+
- Updated documentation to clarify that private directories override config settings for security
|
|
31
|
+
|
|
8
32
|
## [1.8.0] - 2025-07-26
|
|
9
33
|
|
|
10
34
|
### Added
|
package/assets/js/main.js
CHANGED
|
@@ -665,12 +665,16 @@ document.addEventListener('click', (e) => {
|
|
|
665
665
|
document.querySelectorAll('a[href^="#"]').forEach(anchor => {
|
|
666
666
|
anchor.addEventListener('click', function (e) {
|
|
667
667
|
e.preventDefault();
|
|
668
|
-
const
|
|
669
|
-
if (
|
|
670
|
-
|
|
671
|
-
|
|
672
|
-
|
|
673
|
-
|
|
668
|
+
const href = this.getAttribute('href');
|
|
669
|
+
// Skip if href is just '#' (prevents querySelector error)
|
|
670
|
+
if (href && href !== '#') {
|
|
671
|
+
const target = document.querySelector(href);
|
|
672
|
+
if (target) {
|
|
673
|
+
target.scrollIntoView({
|
|
674
|
+
behavior: 'smooth',
|
|
675
|
+
block: 'start'
|
|
676
|
+
});
|
|
677
|
+
}
|
|
674
678
|
}
|
|
675
679
|
});
|
|
676
680
|
});
|
package/html/README.html
CHANGED
|
@@ -46,6 +46,39 @@
|
|
|
46
46
|
<link rel="stylesheet" href="/css/notion-style.css">
|
|
47
47
|
|
|
48
48
|
|
|
49
|
+
<!-- Hide content until auth check -->
|
|
50
|
+
<style>
|
|
51
|
+
body {
|
|
52
|
+
visibility: hidden;
|
|
53
|
+
opacity: 0;
|
|
54
|
+
transition: opacity 0.3s ease;
|
|
55
|
+
}
|
|
56
|
+
body.authenticated {
|
|
57
|
+
visibility: visible;
|
|
58
|
+
opacity: 1;
|
|
59
|
+
}
|
|
60
|
+
/* Show login/logout pages immediately */
|
|
61
|
+
body.auth-page {
|
|
62
|
+
visibility: visible;
|
|
63
|
+
opacity: 1;
|
|
64
|
+
}
|
|
65
|
+
/* Style auth button consistently */
|
|
66
|
+
.auth-btn {
|
|
67
|
+
background: none;
|
|
68
|
+
border: none;
|
|
69
|
+
color: var(--text-secondary);
|
|
70
|
+
cursor: pointer;
|
|
71
|
+
padding: 0.5rem;
|
|
72
|
+
border-radius: 0.5rem;
|
|
73
|
+
transition: all 0.2s;
|
|
74
|
+
font-size: 1.1rem;
|
|
75
|
+
}
|
|
76
|
+
.auth-btn:hover {
|
|
77
|
+
background: var(--bg-secondary);
|
|
78
|
+
color: var(--text-primary);
|
|
79
|
+
}
|
|
80
|
+
</style>
|
|
81
|
+
|
|
49
82
|
|
|
50
83
|
<!-- Favicon -->
|
|
51
84
|
<link rel="icon" href="data:image/svg+xml,<svg xmlns=%22http://www.w3.org/2000/svg%22 viewBox=%220 0 100 100%22><text y=%22.9em%22 font-size=%2290%22>✨</text></svg>">
|
|
@@ -65,8 +98,8 @@
|
|
|
65
98
|
"name": "Knowcode Ltd",
|
|
66
99
|
"url": "https://knowcode.tech"
|
|
67
100
|
},
|
|
68
|
-
"datePublished": "2025-07-
|
|
69
|
-
"dateModified": "2025-07-
|
|
101
|
+
"datePublished": "2025-07-26T10:38:41.951Z",
|
|
102
|
+
"dateModified": "2025-07-26T10:38:41.951Z",
|
|
70
103
|
"mainEntityOfPage": {
|
|
71
104
|
"@type": "WebPage",
|
|
72
105
|
"@id": "https://doc-builder-delta.vercel.app/README.html"
|
|
@@ -99,10 +132,14 @@
|
|
|
99
132
|
|
|
100
133
|
<div class="header-actions">
|
|
101
134
|
<div class="deployment-info">
|
|
102
|
-
<span class="deployment-date" title="Built with doc-builder v1.8.
|
|
135
|
+
<span class="deployment-date" title="Built with doc-builder v1.8.1">Last updated: Jul 26, 2025, 10:38 AM UTC</span>
|
|
103
136
|
</div>
|
|
104
137
|
|
|
105
138
|
|
|
139
|
+
<a href="../login.html" class="auth-btn" title="Login/Logout">
|
|
140
|
+
<i class="fas fa-sign-in-alt"></i>
|
|
141
|
+
</a>
|
|
142
|
+
|
|
106
143
|
|
|
107
144
|
<button id="theme-toggle" class="theme-toggle" aria-label="Toggle theme">
|
|
108
145
|
<i class="fas fa-moon"></i>
|
|
@@ -162,7 +199,7 @@
|
|
|
162
199
|
<a href="/guides/claude-workflow-guide.html" class="nav-item" data-tooltip="This guide demonstrates an efficient workflow for using Claude Code with a refined CLAUDE.md file to create high-quality documentation and deploy it..."><i class="fas fa-file-alt"></i> Claude Workflow Guide</a>
|
|
163
200
|
<a href="/guides/documentation-standards.html" class="nav-item" data-tooltip="This document defines the documentation standards and conventions for the @knowcode/doc-builder project."><i class="fas fa-file-alt"></i> Documentation Standards</a>
|
|
164
201
|
<a href="/guides/phosphor-icons-guide.html" class="nav-item" data-tooltip="@knowcode/doc-builder automatically converts Unicode emojis in your markdown files to beautiful Phosphor icons in the generated HTML."><i class="fas fa-file-alt"></i> Phosphor Icons Guide</a>
|
|
165
|
-
<a href="/guides/private-directory-authentication.html" class="nav-item" data-tooltip="The @knowcode/doc-builder
|
|
202
|
+
<a href="/guides/private-directory-authentication.html" class="nav-item" data-tooltip="The @knowcode/doc-builder provides flexible authentication options to protect your documentation."><i class="fas fa-file-alt"></i> Private Directory Authentication</a>
|
|
166
203
|
<a href="/guides/public-site-deployment.html" class="nav-item" data-tooltip="The @knowcode/doc-builder now supports deploying public documentation sites without authentication."><i class="fas fa-file-alt"></i> Public Site Deployment</a>
|
|
167
204
|
<a href="/guides/search-engine-verification-guide.html" class="nav-item" data-tooltip="Search engine verification provides access to powerful webmaster tools:."><i class="fas fa-file-alt"></i> Search Engine Verification Guide</a>
|
|
168
205
|
<a href="/guides/seo-guide.html" class="nav-item" data-tooltip="@knowcode/doc-builder includes comprehensive SEO (Search Engine Optimization) features to help your documentation rank better in search results and..."><i class="fas fa-file-alt"></i> Seo Guide</a>
|
|
@@ -428,6 +465,7 @@ docBuilder.build({
|
|
|
428
465
|
};
|
|
429
466
|
</script>
|
|
430
467
|
<script src="/js/main.js"></script>
|
|
431
|
-
|
|
468
|
+
<script src="https://unpkg.com/@supabase/supabase-js@2"></script>
|
|
469
|
+
<script src="/js/auth.js"></script>
|
|
432
470
|
</body>
|
|
433
471
|
</html>
|
package/html/auth.js
CHANGED
|
@@ -27,11 +27,22 @@
|
|
|
27
27
|
// Check authentication and site access
|
|
28
28
|
async function checkAuth() {
|
|
29
29
|
try {
|
|
30
|
+
// Check if current page is in private directory
|
|
31
|
+
const currentPath = window.location.pathname;
|
|
32
|
+
const isPrivatePage = currentPath.includes('/private/');
|
|
33
|
+
|
|
30
34
|
// Get current user session
|
|
31
35
|
const { data: { user }, error: userError } = await supabaseClient.auth.getUser();
|
|
32
36
|
|
|
33
37
|
if (userError || !user) {
|
|
34
|
-
|
|
38
|
+
// Only redirect if we're on a private page
|
|
39
|
+
if (isPrivatePage) {
|
|
40
|
+
redirectToLogin();
|
|
41
|
+
} else {
|
|
42
|
+
// Public page, just show it
|
|
43
|
+
document.body.classList.add('authenticated'); // Use same class to show body
|
|
44
|
+
updateAuthButton(false);
|
|
45
|
+
}
|
|
35
46
|
return;
|
|
36
47
|
}
|
|
37
48
|
|
|
@@ -40,21 +51,34 @@
|
|
|
40
51
|
.from('docbuilder_access')
|
|
41
52
|
.select('*')
|
|
42
53
|
.eq('user_id', user.id)
|
|
43
|
-
.eq('site_id', '
|
|
54
|
+
.eq('site_id', '-knowcode-doc-builder-1753526321904-eivutk')
|
|
44
55
|
.single();
|
|
45
56
|
|
|
46
57
|
if (accessError || !access) {
|
|
47
|
-
|
|
58
|
+
if (isPrivatePage) {
|
|
59
|
+
showAccessDenied();
|
|
60
|
+
} else {
|
|
61
|
+
// Public page, just show it
|
|
62
|
+
document.body.classList.add('authenticated');
|
|
63
|
+
updateAuthButton(false);
|
|
64
|
+
}
|
|
48
65
|
return;
|
|
49
66
|
}
|
|
50
67
|
|
|
51
68
|
// User is authenticated and has access
|
|
52
69
|
console.log('User authenticated and authorized');
|
|
53
70
|
document.body.classList.add('authenticated');
|
|
71
|
+
updateAuthButton(true);
|
|
54
72
|
|
|
55
73
|
} catch (error) {
|
|
56
74
|
console.error('Auth check failed:', error);
|
|
57
|
-
|
|
75
|
+
if (window.location.pathname.includes('/private/')) {
|
|
76
|
+
redirectToLogin();
|
|
77
|
+
} else {
|
|
78
|
+
// Public page, show it anyway
|
|
79
|
+
document.body.classList.add('authenticated');
|
|
80
|
+
updateAuthButton(false);
|
|
81
|
+
}
|
|
58
82
|
}
|
|
59
83
|
}
|
|
60
84
|
|
|
@@ -79,16 +103,41 @@
|
|
|
79
103
|
`;
|
|
80
104
|
}
|
|
81
105
|
|
|
82
|
-
//
|
|
106
|
+
// Function to update auth button
|
|
107
|
+
function updateAuthButton(isAuthenticated) {
|
|
108
|
+
const authBtn = document.querySelector('.auth-btn');
|
|
109
|
+
if (authBtn) {
|
|
110
|
+
const icon = authBtn.querySelector('i');
|
|
111
|
+
if (icon) {
|
|
112
|
+
if (isAuthenticated) {
|
|
113
|
+
icon.className = 'fas fa-sign-out-alt';
|
|
114
|
+
authBtn.title = 'Logout';
|
|
115
|
+
authBtn.href = '/logout.html';
|
|
116
|
+
} else {
|
|
117
|
+
icon.className = 'fas fa-sign-in-alt';
|
|
118
|
+
authBtn.title = 'Login';
|
|
119
|
+
authBtn.href = '/login.html';
|
|
120
|
+
}
|
|
121
|
+
}
|
|
122
|
+
}
|
|
123
|
+
}
|
|
124
|
+
|
|
125
|
+
// Add auth button functionality
|
|
83
126
|
document.addEventListener('DOMContentLoaded', function() {
|
|
84
|
-
const
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
await supabaseClient.auth.
|
|
89
|
-
|
|
127
|
+
const authBtn = document.querySelector('.auth-btn');
|
|
128
|
+
if (authBtn) {
|
|
129
|
+
authBtn.addEventListener('click', async function(e) {
|
|
130
|
+
// Check if we're logged in
|
|
131
|
+
const { data: { user } } = await supabaseClient.auth.getUser();
|
|
132
|
+
if (user) {
|
|
133
|
+
// Logged in - sign out
|
|
134
|
+
e.preventDefault();
|
|
135
|
+
await supabaseClient.auth.signOut();
|
|
136
|
+
window.location.href = '/logout.html';
|
|
137
|
+
}
|
|
138
|
+
// If not logged in, normal navigation to login page will occur
|
|
90
139
|
});
|
|
91
|
-
}
|
|
140
|
+
}
|
|
92
141
|
});
|
|
93
142
|
|
|
94
143
|
// Run auth check
|
|
@@ -46,6 +46,39 @@
|
|
|
46
46
|
<link rel="stylesheet" href="/css/notion-style.css">
|
|
47
47
|
|
|
48
48
|
|
|
49
|
+
<!-- Hide content until auth check -->
|
|
50
|
+
<style>
|
|
51
|
+
body {
|
|
52
|
+
visibility: hidden;
|
|
53
|
+
opacity: 0;
|
|
54
|
+
transition: opacity 0.3s ease;
|
|
55
|
+
}
|
|
56
|
+
body.authenticated {
|
|
57
|
+
visibility: visible;
|
|
58
|
+
opacity: 1;
|
|
59
|
+
}
|
|
60
|
+
/* Show login/logout pages immediately */
|
|
61
|
+
body.auth-page {
|
|
62
|
+
visibility: visible;
|
|
63
|
+
opacity: 1;
|
|
64
|
+
}
|
|
65
|
+
/* Style auth button consistently */
|
|
66
|
+
.auth-btn {
|
|
67
|
+
background: none;
|
|
68
|
+
border: none;
|
|
69
|
+
color: var(--text-secondary);
|
|
70
|
+
cursor: pointer;
|
|
71
|
+
padding: 0.5rem;
|
|
72
|
+
border-radius: 0.5rem;
|
|
73
|
+
transition: all 0.2s;
|
|
74
|
+
font-size: 1.1rem;
|
|
75
|
+
}
|
|
76
|
+
.auth-btn:hover {
|
|
77
|
+
background: var(--bg-secondary);
|
|
78
|
+
color: var(--text-primary);
|
|
79
|
+
}
|
|
80
|
+
</style>
|
|
81
|
+
|
|
49
82
|
|
|
50
83
|
<!-- Favicon -->
|
|
51
84
|
<link rel="icon" href="data:image/svg+xml,<svg xmlns=%22http://www.w3.org/2000/svg%22 viewBox=%220 0 100 100%22><text y=%22.9em%22 font-size=%2290%22>✨</text></svg>">
|
|
@@ -65,8 +98,8 @@
|
|
|
65
98
|
"name": "Knowcode Ltd",
|
|
66
99
|
"url": "https://knowcode.tech"
|
|
67
100
|
},
|
|
68
|
-
"datePublished": "2025-07-
|
|
69
|
-
"dateModified": "2025-07-
|
|
101
|
+
"datePublished": "2025-07-26T10:38:41.963Z",
|
|
102
|
+
"dateModified": "2025-07-26T10:38:41.963Z",
|
|
70
103
|
"mainEntityOfPage": {
|
|
71
104
|
"@type": "WebPage",
|
|
72
105
|
"@id": "https://doc-builder-delta.vercel.app/documentation-index.html"
|
|
@@ -99,10 +132,14 @@
|
|
|
99
132
|
|
|
100
133
|
<div class="header-actions">
|
|
101
134
|
<div class="deployment-info">
|
|
102
|
-
<span class="deployment-date" title="Built with doc-builder v1.8.
|
|
135
|
+
<span class="deployment-date" title="Built with doc-builder v1.8.1">Last updated: Jul 26, 2025, 10:38 AM UTC</span>
|
|
103
136
|
</div>
|
|
104
137
|
|
|
105
138
|
|
|
139
|
+
<a href="../login.html" class="auth-btn" title="Login/Logout">
|
|
140
|
+
<i class="fas fa-sign-in-alt"></i>
|
|
141
|
+
</a>
|
|
142
|
+
|
|
106
143
|
|
|
107
144
|
<button id="theme-toggle" class="theme-toggle" aria-label="Toggle theme">
|
|
108
145
|
<i class="fas fa-moon"></i>
|
|
@@ -162,7 +199,7 @@
|
|
|
162
199
|
<a href="/guides/claude-workflow-guide.html" class="nav-item" data-tooltip="This guide demonstrates an efficient workflow for using Claude Code with a refined CLAUDE.md file to create high-quality documentation and deploy it..."><i class="fas fa-file-alt"></i> Claude Workflow Guide</a>
|
|
163
200
|
<a href="/guides/documentation-standards.html" class="nav-item" data-tooltip="This document defines the documentation standards and conventions for the @knowcode/doc-builder project."><i class="fas fa-file-alt"></i> Documentation Standards</a>
|
|
164
201
|
<a href="/guides/phosphor-icons-guide.html" class="nav-item" data-tooltip="@knowcode/doc-builder automatically converts Unicode emojis in your markdown files to beautiful Phosphor icons in the generated HTML."><i class="fas fa-file-alt"></i> Phosphor Icons Guide</a>
|
|
165
|
-
<a href="/guides/private-directory-authentication.html" class="nav-item" data-tooltip="The @knowcode/doc-builder
|
|
202
|
+
<a href="/guides/private-directory-authentication.html" class="nav-item" data-tooltip="The @knowcode/doc-builder provides flexible authentication options to protect your documentation."><i class="fas fa-file-alt"></i> Private Directory Authentication</a>
|
|
166
203
|
<a href="/guides/public-site-deployment.html" class="nav-item" data-tooltip="The @knowcode/doc-builder now supports deploying public documentation sites without authentication."><i class="fas fa-file-alt"></i> Public Site Deployment</a>
|
|
167
204
|
<a href="/guides/search-engine-verification-guide.html" class="nav-item" data-tooltip="Search engine verification provides access to powerful webmaster tools:."><i class="fas fa-file-alt"></i> Search Engine Verification Guide</a>
|
|
168
205
|
<a href="/guides/seo-guide.html" class="nav-item" data-tooltip="@knowcode/doc-builder includes comprehensive SEO (Search Engine Optimization) features to help your documentation rank better in search results and..."><i class="fas fa-file-alt"></i> Seo Guide</a>
|
|
@@ -368,6 +405,7 @@ Detailed information...
|
|
|
368
405
|
};
|
|
369
406
|
</script>
|
|
370
407
|
<script src="/js/main.js"></script>
|
|
371
|
-
|
|
408
|
+
<script src="https://unpkg.com/@supabase/supabase-js@2"></script>
|
|
409
|
+
<script src="/js/auth.js"></script>
|
|
372
410
|
</body>
|
|
373
411
|
</html>
|
|
@@ -46,6 +46,39 @@
|
|
|
46
46
|
<link rel="stylesheet" href="/css/notion-style.css">
|
|
47
47
|
|
|
48
48
|
|
|
49
|
+
<!-- Hide content until auth check -->
|
|
50
|
+
<style>
|
|
51
|
+
body {
|
|
52
|
+
visibility: hidden;
|
|
53
|
+
opacity: 0;
|
|
54
|
+
transition: opacity 0.3s ease;
|
|
55
|
+
}
|
|
56
|
+
body.authenticated {
|
|
57
|
+
visibility: visible;
|
|
58
|
+
opacity: 1;
|
|
59
|
+
}
|
|
60
|
+
/* Show login/logout pages immediately */
|
|
61
|
+
body.auth-page {
|
|
62
|
+
visibility: visible;
|
|
63
|
+
opacity: 1;
|
|
64
|
+
}
|
|
65
|
+
/* Style auth button consistently */
|
|
66
|
+
.auth-btn {
|
|
67
|
+
background: none;
|
|
68
|
+
border: none;
|
|
69
|
+
color: var(--text-secondary);
|
|
70
|
+
cursor: pointer;
|
|
71
|
+
padding: 0.5rem;
|
|
72
|
+
border-radius: 0.5rem;
|
|
73
|
+
transition: all 0.2s;
|
|
74
|
+
font-size: 1.1rem;
|
|
75
|
+
}
|
|
76
|
+
.auth-btn:hover {
|
|
77
|
+
background: var(--bg-secondary);
|
|
78
|
+
color: var(--text-primary);
|
|
79
|
+
}
|
|
80
|
+
</style>
|
|
81
|
+
|
|
49
82
|
|
|
50
83
|
<!-- Favicon -->
|
|
51
84
|
<link rel="icon" href="data:image/svg+xml,<svg xmlns=%22http://www.w3.org/2000/svg%22 viewBox=%220 0 100 100%22><text y=%22.9em%22 font-size=%2290%22>✨</text></svg>">
|
|
@@ -65,8 +98,8 @@
|
|
|
65
98
|
"name": "Knowcode Ltd",
|
|
66
99
|
"url": "https://knowcode.tech"
|
|
67
100
|
},
|
|
68
|
-
"datePublished": "2025-07-
|
|
69
|
-
"dateModified": "2025-07-
|
|
101
|
+
"datePublished": "2025-07-26T10:38:41.967Z",
|
|
102
|
+
"dateModified": "2025-07-26T10:38:41.967Z",
|
|
70
103
|
"mainEntityOfPage": {
|
|
71
104
|
"@type": "WebPage",
|
|
72
105
|
"@id": "https://doc-builder-delta.vercel.app/guides/authentication-default-change.html"
|
|
@@ -105,10 +138,14 @@
|
|
|
105
138
|
|
|
106
139
|
<div class="header-actions">
|
|
107
140
|
<div class="deployment-info">
|
|
108
|
-
<span class="deployment-date" title="Built with doc-builder v1.8.
|
|
141
|
+
<span class="deployment-date" title="Built with doc-builder v1.8.1">Last updated: Jul 26, 2025, 10:38 AM UTC</span>
|
|
109
142
|
</div>
|
|
110
143
|
|
|
111
144
|
|
|
145
|
+
<a href="../../login.html" class="auth-btn" title="Login/Logout">
|
|
146
|
+
<i class="fas fa-sign-in-alt"></i>
|
|
147
|
+
</a>
|
|
148
|
+
|
|
112
149
|
|
|
113
150
|
<button id="theme-toggle" class="theme-toggle" aria-label="Toggle theme">
|
|
114
151
|
<i class="fas fa-moon"></i>
|
|
@@ -168,7 +205,7 @@
|
|
|
168
205
|
<a href="/guides/claude-workflow-guide.html" class="nav-item" data-tooltip="This guide demonstrates an efficient workflow for using Claude Code with a refined CLAUDE.md file to create high-quality documentation and deploy it..."><i class="fas fa-file-alt"></i> Claude Workflow Guide</a>
|
|
169
206
|
<a href="/guides/documentation-standards.html" class="nav-item" data-tooltip="This document defines the documentation standards and conventions for the @knowcode/doc-builder project."><i class="fas fa-file-alt"></i> Documentation Standards</a>
|
|
170
207
|
<a href="/guides/phosphor-icons-guide.html" class="nav-item" data-tooltip="@knowcode/doc-builder automatically converts Unicode emojis in your markdown files to beautiful Phosphor icons in the generated HTML."><i class="fas fa-file-alt"></i> Phosphor Icons Guide</a>
|
|
171
|
-
<a href="/guides/private-directory-authentication.html" class="nav-item" data-tooltip="The @knowcode/doc-builder
|
|
208
|
+
<a href="/guides/private-directory-authentication.html" class="nav-item" data-tooltip="The @knowcode/doc-builder provides flexible authentication options to protect your documentation."><i class="fas fa-file-alt"></i> Private Directory Authentication</a>
|
|
172
209
|
<a href="/guides/public-site-deployment.html" class="nav-item" data-tooltip="The @knowcode/doc-builder now supports deploying public documentation sites without authentication."><i class="fas fa-file-alt"></i> Public Site Deployment</a>
|
|
173
210
|
<a href="/guides/search-engine-verification-guide.html" class="nav-item" data-tooltip="Search engine verification provides access to powerful webmaster tools:."><i class="fas fa-file-alt"></i> Search Engine Verification Guide</a>
|
|
174
211
|
<a href="/guides/seo-guide.html" class="nav-item" data-tooltip="@knowcode/doc-builder includes comprehensive SEO (Search Engine Optimization) features to help your documentation rank better in search results and..."><i class="fas fa-file-alt"></i> Seo Guide</a>
|
|
@@ -283,6 +320,7 @@ module.exports = {
|
|
|
283
320
|
};
|
|
284
321
|
</script>
|
|
285
322
|
<script src="/js/main.js"></script>
|
|
286
|
-
|
|
323
|
+
<script src="https://unpkg.com/@supabase/supabase-js@2"></script>
|
|
324
|
+
<script src="/js/auth.js"></script>
|
|
287
325
|
</body>
|
|
288
326
|
</html>
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
<head>
|
|
4
4
|
<meta charset="UTF-8">
|
|
5
5
|
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
|
6
|
-
<meta name="description" content="
|
|
6
|
+
<meta name="description" content="> 🎉 Update v1.8.2: Supabase credentials are now automatically configured! No manual setup needed - just enable authentication and add users to the database.">
|
|
7
7
|
<title>Authentication Guide for @knowcode/doc-builder</title>
|
|
8
8
|
|
|
9
9
|
<meta name="author" content="Lindsay Smith">
|
|
@@ -15,7 +15,7 @@
|
|
|
15
15
|
<meta property="og:type" content="article">
|
|
16
16
|
<meta property="og:url" content="https://doc-builder-delta.vercel.app/guides/authentication-guide.html">
|
|
17
17
|
<meta property="og:title" content="Authentication Guide for @knowcode/doc-builder">
|
|
18
|
-
<meta property="og:description" content="
|
|
18
|
+
<meta property="og:description" content="> 🎉 Update v1.8.2: Supabase credentials are now automatically configured! No manual setup needed - just enable authentication and add users to the database.">
|
|
19
19
|
<meta property="og:image" content="https://doc-builder-delta.vercel.app/og-default.png">
|
|
20
20
|
<meta property="og:site_name" content="@knowcode/doc-builder">
|
|
21
21
|
<meta property="og:locale" content="en_US">
|
|
@@ -25,7 +25,7 @@
|
|
|
25
25
|
<meta name="twitter:site" content="@planbbackups">
|
|
26
26
|
<meta name="twitter:creator" content="@planbbackups">
|
|
27
27
|
<meta name="twitter:title" content="Authentication Guide for @knowcode/doc-builder">
|
|
28
|
-
<meta name="twitter:description" content="
|
|
28
|
+
<meta name="twitter:description" content="> 🎉 Update v1.8.2: Supabase credentials are now automatically configured! No manual setup needed - just enable authentication and add users to the database.">
|
|
29
29
|
<meta name="twitter:image" content="https://doc-builder-delta.vercel.app/og-default.png">
|
|
30
30
|
|
|
31
31
|
<!-- Custom Meta Tags -->
|
|
@@ -46,6 +46,39 @@
|
|
|
46
46
|
<link rel="stylesheet" href="/css/notion-style.css">
|
|
47
47
|
|
|
48
48
|
|
|
49
|
+
<!-- Hide content until auth check -->
|
|
50
|
+
<style>
|
|
51
|
+
body {
|
|
52
|
+
visibility: hidden;
|
|
53
|
+
opacity: 0;
|
|
54
|
+
transition: opacity 0.3s ease;
|
|
55
|
+
}
|
|
56
|
+
body.authenticated {
|
|
57
|
+
visibility: visible;
|
|
58
|
+
opacity: 1;
|
|
59
|
+
}
|
|
60
|
+
/* Show login/logout pages immediately */
|
|
61
|
+
body.auth-page {
|
|
62
|
+
visibility: visible;
|
|
63
|
+
opacity: 1;
|
|
64
|
+
}
|
|
65
|
+
/* Style auth button consistently */
|
|
66
|
+
.auth-btn {
|
|
67
|
+
background: none;
|
|
68
|
+
border: none;
|
|
69
|
+
color: var(--text-secondary);
|
|
70
|
+
cursor: pointer;
|
|
71
|
+
padding: 0.5rem;
|
|
72
|
+
border-radius: 0.5rem;
|
|
73
|
+
transition: all 0.2s;
|
|
74
|
+
font-size: 1.1rem;
|
|
75
|
+
}
|
|
76
|
+
.auth-btn:hover {
|
|
77
|
+
background: var(--bg-secondary);
|
|
78
|
+
color: var(--text-primary);
|
|
79
|
+
}
|
|
80
|
+
</style>
|
|
81
|
+
|
|
49
82
|
|
|
50
83
|
<!-- Favicon -->
|
|
51
84
|
<link rel="icon" href="data:image/svg+xml,<svg xmlns=%22http://www.w3.org/2000/svg%22 viewBox=%220 0 100 100%22><text y=%22.9em%22 font-size=%2290%22>✨</text></svg>">
|
|
@@ -55,7 +88,7 @@
|
|
|
55
88
|
"@context": "https://schema.org",
|
|
56
89
|
"@type": "TechArticle",
|
|
57
90
|
"headline": "Authentication Guide for @knowcode/doc-builder",
|
|
58
|
-
"description": "
|
|
91
|
+
"description": "> 🎉 Update v1.8.2: Supabase credentials are now automatically configured! No manual setup needed - just enable authentication and add users to the database.",
|
|
59
92
|
"author": {
|
|
60
93
|
"@type": "Person",
|
|
61
94
|
"name": "Lindsay Smith"
|
|
@@ -65,8 +98,8 @@
|
|
|
65
98
|
"name": "Knowcode Ltd",
|
|
66
99
|
"url": "https://knowcode.tech"
|
|
67
100
|
},
|
|
68
|
-
"datePublished": "2025-07-
|
|
69
|
-
"dateModified": "2025-07-
|
|
101
|
+
"datePublished": "2025-07-26T10:38:41.969Z",
|
|
102
|
+
"dateModified": "2025-07-26T10:38:41.969Z",
|
|
70
103
|
"mainEntityOfPage": {
|
|
71
104
|
"@type": "WebPage",
|
|
72
105
|
"@id": "https://doc-builder-delta.vercel.app/guides/authentication-guide.html"
|
|
@@ -105,10 +138,14 @@
|
|
|
105
138
|
|
|
106
139
|
<div class="header-actions">
|
|
107
140
|
<div class="deployment-info">
|
|
108
|
-
<span class="deployment-date" title="Built with doc-builder v1.8.
|
|
141
|
+
<span class="deployment-date" title="Built with doc-builder v1.8.1">Last updated: Jul 26, 2025, 10:38 AM UTC</span>
|
|
109
142
|
</div>
|
|
110
143
|
|
|
111
144
|
|
|
145
|
+
<a href="../../login.html" class="auth-btn" title="Login/Logout">
|
|
146
|
+
<i class="fas fa-sign-in-alt"></i>
|
|
147
|
+
</a>
|
|
148
|
+
|
|
112
149
|
|
|
113
150
|
<button id="theme-toggle" class="theme-toggle" aria-label="Toggle theme">
|
|
114
151
|
<i class="fas fa-moon"></i>
|
|
@@ -168,7 +205,7 @@
|
|
|
168
205
|
<a href="/guides/claude-workflow-guide.html" class="nav-item" data-tooltip="This guide demonstrates an efficient workflow for using Claude Code with a refined CLAUDE.md file to create high-quality documentation and deploy it..."><i class="fas fa-file-alt"></i> Claude Workflow Guide</a>
|
|
169
206
|
<a href="/guides/documentation-standards.html" class="nav-item" data-tooltip="This document defines the documentation standards and conventions for the @knowcode/doc-builder project."><i class="fas fa-file-alt"></i> Documentation Standards</a>
|
|
170
207
|
<a href="/guides/phosphor-icons-guide.html" class="nav-item" data-tooltip="@knowcode/doc-builder automatically converts Unicode emojis in your markdown files to beautiful Phosphor icons in the generated HTML."><i class="fas fa-file-alt"></i> Phosphor Icons Guide</a>
|
|
171
|
-
<a href="/guides/private-directory-authentication.html" class="nav-item" data-tooltip="The @knowcode/doc-builder
|
|
208
|
+
<a href="/guides/private-directory-authentication.html" class="nav-item" data-tooltip="The @knowcode/doc-builder provides flexible authentication options to protect your documentation."><i class="fas fa-file-alt"></i> Private Directory Authentication</a>
|
|
172
209
|
<a href="/guides/public-site-deployment.html" class="nav-item" data-tooltip="The @knowcode/doc-builder now supports deploying public documentation sites without authentication."><i class="fas fa-file-alt"></i> Public Site Deployment</a>
|
|
173
210
|
<a href="/guides/search-engine-verification-guide.html" class="nav-item" data-tooltip="Search engine verification provides access to powerful webmaster tools:."><i class="fas fa-file-alt"></i> Search Engine Verification Guide</a>
|
|
174
211
|
<a href="/guides/seo-guide.html" class="nav-item" data-tooltip="@knowcode/doc-builder includes comprehensive SEO (Search Engine Optimization) features to help your documentation rank better in search results and..."><i class="fas fa-file-alt"></i> Seo Guide</a>
|
|
@@ -183,6 +220,9 @@
|
|
|
183
220
|
<main class="content">
|
|
184
221
|
<div class="content-inner">
|
|
185
222
|
<h1>Authentication Guide for @knowcode/doc-builder</h1>
|
|
223
|
+
<blockquote>
|
|
224
|
+
<p><strong><i class="ph ph-confetti" aria-label="party"></i> Update v1.8.2</strong>: Supabase credentials are now automatically configured! No manual setup needed - just enable authentication and add users to the database.</p>
|
|
225
|
+
</blockquote>
|
|
186
226
|
<h2>Overview</h2>
|
|
187
227
|
<p>@knowcode/doc-builder supports enterprise-grade authentication through <strong>Supabase</strong> - a secure, scalable authentication platform. This guide explains how to protect your documentation with proper user authentication and access control.</p>
|
|
188
228
|
<h2>Why Supabase?</h2>
|
|
@@ -414,6 +454,7 @@ auth: {
|
|
|
414
454
|
};
|
|
415
455
|
</script>
|
|
416
456
|
<script src="/js/main.js"></script>
|
|
417
|
-
|
|
457
|
+
<script src="https://unpkg.com/@supabase/supabase-js@2"></script>
|
|
458
|
+
<script src="/js/auth.js"></script>
|
|
418
459
|
</body>
|
|
419
460
|
</html>
|