mirror of
https://github.com/Memo-2023/mana-monorepo.git
synced 2026-05-18 19:41:23 +02:00
chore: add techbase to apps-archived
Integrated techbase (software comparison platform) into monorepo structure: - Created NestJS backend with votes and comments modules - Migrated from external Supabase to own PostgreSQL - Set up Drizzle ORM schema for votes and comments - Created API client replacing Supabase in Astro frontend - Added environment configuration (port 3021) Archived immediately as it's not yet ready for active development. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
parent
17313473aa
commit
34c879929b
161 changed files with 12613 additions and 0 deletions
49
apps-archived/techbase/apps/web/src/scripts/softwarePage.js
Normal file
49
apps-archived/techbase/apps/web/src/scripts/softwarePage.js
Normal file
|
|
@ -0,0 +1,49 @@
|
|||
// Software page Alpine.js initialization
|
||||
function initSoftwarePage() {
|
||||
return {
|
||||
isCompareMode: false,
|
||||
selectedSoftwareId: null,
|
||||
currentViewSide: 'left',
|
||||
isLeftMinimized: false,
|
||||
isRightMinimized: false,
|
||||
|
||||
init() {
|
||||
// Check URL for compare parameter
|
||||
const urlParams = new URLSearchParams(window.location.search);
|
||||
const compareWith = urlParams.get('compare');
|
||||
|
||||
if (compareWith) {
|
||||
this.isCompareMode = true;
|
||||
this.selectedSoftwareId = compareWith;
|
||||
}
|
||||
},
|
||||
|
||||
toggleCompareMode() {
|
||||
this.isCompareMode = !this.isCompareMode;
|
||||
if (!this.isCompareMode) {
|
||||
const url = new URL(window.location.href);
|
||||
url.searchParams.delete('compare');
|
||||
window.history.pushState({}, '', url.toString());
|
||||
this.selectedSoftwareId = null;
|
||||
}
|
||||
},
|
||||
|
||||
switchViewSide(side) {
|
||||
this.currentViewSide = side;
|
||||
},
|
||||
|
||||
toggleMinimize(side) {
|
||||
if (side === 'left') {
|
||||
this.isLeftMinimized = !this.isLeftMinimized;
|
||||
if (this.isLeftMinimized && this.isRightMinimized) {
|
||||
this.isRightMinimized = false;
|
||||
}
|
||||
} else {
|
||||
this.isRightMinimized = !this.isRightMinimized;
|
||||
if (this.isRightMinimized && this.isLeftMinimized) {
|
||||
this.isLeftMinimized = false;
|
||||
}
|
||||
}
|
||||
}
|
||||
};
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue