Skip to content

Commit 4286cef

Browse files
authored
Merge pull request #1090 from datum-cloud/chore/remove-embedded-docs-content-and-drop-regeneration-workflows
chore: remove embedded docs content and drop regeneration workflows
2 parents e0a4caf + 58caa51 commit 4286cef

File tree

102 files changed

+70
-14373
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

102 files changed

+70
-14373
lines changed

.github/workflows/regenerate-api-docs.yml

Lines changed: 0 additions & 58 deletions
This file was deleted.

.github/workflows/regenerate-datumctl-docs.yaml

Lines changed: 0 additions & 58 deletions
This file was deleted.

server.mjs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -62,6 +62,7 @@ const REDIRECTS = {
6262
'/jobs/': { destination: '/careers/', status: 302 },
6363
'/community-huddle/': { destination: '/events/', status: 302 },
6464
'/docs/': { destination: '/docs/overview/', status: 302 },
65+
'/docs': { destination: '/docs/overview/', status: 302 },
6566
'/docs/roadmap': { destination: '/resources/roadmap/', status: 302 },
6667
'/docs/tutorials/gateway': { destination: '/docs/tutorials/httpproxy/', status: 302 },
6768
'/docs/get-started/datum-concepts/': {

src/components/about/ProfileModal.astro

Lines changed: 56 additions & 58 deletions
Original file line numberDiff line numberDiff line change
@@ -147,69 +147,67 @@ const { class: className } = Astro.props as { class?: string };
147147

148148
// Color palette that cycles through (matches @utils/authorUtils.ts)
149149
const bgColors = ['#5F735E', '#BF9595', '#D1CDC0'];
150-
const getBgColor = (index: number): string => {
151-
return bgColors[index % bgColors.length];
152-
};
150+
const getBgColor = (index: number): string => bgColors[index % bgColors.length];
153151
const bgColor = member.index !== undefined ? getBgColor(member.index) : bgColors[0];
154152

155-
// Build avatar HTML
156-
const avatarHTML = data.avatar
157-
? `<div class="profile-modal--avatar" style="background-color: ${bgColor}">
158-
<img src="${data.avatar.src}" alt="${data.name}" />
159-
</div>`
160-
: '';
161-
162-
// Build meta grid items
163-
const metaItems = [];
164-
165-
if (data.bio) {
166-
metaItems.push(`
167-
<div class="profile-modal--meta-item">
168-
<label>About</label>
169-
<p>${data.bio}</p>
170-
</div>
171-
`);
153+
this.contentContainer.textContent = '';
154+
155+
// Row 1: avatar + info
156+
const rowFirst = document.createElement('div');
157+
rowFirst.className = 'profile-modal--row-first';
158+
159+
if (data.avatar) {
160+
const avatarDiv = document.createElement('div');
161+
avatarDiv.className = 'profile-modal--avatar';
162+
avatarDiv.style.backgroundColor = bgColor;
163+
const img = document.createElement('img');
164+
img.src = data.avatar.src;
165+
img.alt = data.name;
166+
avatarDiv.appendChild(img);
167+
rowFirst.appendChild(avatarDiv);
172168
}
173-
if (data.tick) {
174-
metaItems.push(`
175-
<div class="profile-modal--meta-item">
176-
<label>What makes me tick</label>
177-
<p>${data.tick}</p>
178-
</div>
179-
`);
180-
}
181-
if (data.surprising) {
182-
metaItems.push(`
183-
<div class="profile-modal--meta-item">
184-
<label>Something surprising</label>
185-
<p>${data.surprising}</p>
186-
</div>
187-
`);
169+
170+
const infoDiv = document.createElement('div');
171+
infoDiv.className = 'profile-modal--info';
172+
const infoHeader = document.createElement('div');
173+
infoHeader.className = 'profile-modal--info-header';
174+
const h2 = document.createElement('h2');
175+
h2.textContent = data.name;
176+
infoHeader.appendChild(h2);
177+
if (data.title) {
178+
const titleP = document.createElement('p');
179+
titleP.textContent = data.title;
180+
infoHeader.appendChild(titleP);
188181
}
189-
if (data.weekends) {
190-
metaItems.push(`
191-
<div class="profile-modal--meta-item">
192-
<label>On weekends I'm</label>
193-
<p>${data.weekends}</p>
194-
</div>
195-
`);
182+
infoDiv.appendChild(infoHeader);
183+
rowFirst.appendChild(infoDiv);
184+
this.contentContainer.appendChild(rowFirst);
185+
186+
// Row 2: meta items
187+
const metaFields: { label: string; value: string | undefined }[] = [
188+
{ label: 'About', value: data.bio },
189+
{ label: 'What makes me tick', value: data.tick },
190+
{ label: 'Something surprising', value: data.surprising },
191+
{ label: "On weekends I'm", value: data.weekends },
192+
];
193+
194+
const presentFields = metaFields.filter((f) => f.value);
195+
if (presentFields.length > 0) {
196+
const rowSecond = document.createElement('div');
197+
rowSecond.className = 'profile-modal--row-second';
198+
for (const field of presentFields) {
199+
const item = document.createElement('div');
200+
item.className = 'profile-modal--meta-item';
201+
const label = document.createElement('label');
202+
label.textContent = field.label;
203+
const p = document.createElement('p');
204+
p.textContent = field.value!;
205+
item.appendChild(label);
206+
item.appendChild(p);
207+
rowSecond.appendChild(item);
208+
}
209+
this.contentContainer.appendChild(rowSecond);
196210
}
197-
198-
// Populate the content
199-
this.contentContainer.innerHTML = `
200-
<div class="profile-modal--row-first">
201-
${avatarHTML}
202-
<div class="profile-modal--info">
203-
<div class="profile-modal--info-header">
204-
<h2>${data.name}</h2>
205-
${data.title ? `<p>${data.title}</p>` : ''}
206-
</div>
207-
208-
</div>
209-
</div>
210-
211-
${metaItems.length > 0 ? `<div class="profile-modal--row-second">${metaItems.join('')}</div>` : ''}
212-
`;
213211
}
214212
}
215213

src/content/docs/docs/alt-cloud/domain-validation.mdx

Lines changed: 0 additions & 10 deletions
This file was deleted.

src/content/docs/docs/alt-cloud/index.mdx

Lines changed: 0 additions & 10 deletions
This file was deleted.

src/content/docs/docs/api/authenticating.mdx

Lines changed: 0 additions & 38 deletions
This file was deleted.

src/content/docs/docs/api/connecting-to-the-api.mdx

Lines changed: 0 additions & 78 deletions
This file was deleted.

0 commit comments

Comments
 (0)