feat: Reinitialize frontend with SvelteKit and TypeScript

- Delete old Vite+Svelte frontend
- Initialize new SvelteKit project with TypeScript
- Configure Tailwind CSS v4 + DaisyUI
- Implement JWT authentication with auto-refresh
- Create login page with form validation (Zod)
- Add protected route guards
- Update Docker configuration for single-stage build
- Add E2E tests with Playwright (6/11 passing)
- Fix Svelte 5 reactivity with $state() runes

Known issues:
- 5 E2E tests failing (timing/async issues)
- Token refresh implementation needs debugging
- Validation error display timing
This commit is contained in:
2026-02-17 16:19:59 -05:00
parent 54df6018f5
commit de2d83092e
28274 changed files with 3816354 additions and 90 deletions

View File

@@ -0,0 +1,23 @@
import HTMLElement from '../html-element/HTMLElement.js';
import HTMLTableRowElement from '../html-table-row-element/HTMLTableRowElement.js';
/**
* HTMLTableSectionElement
*
* @see https://developer.mozilla.org/en-US/docs/Web/API/HTMLTableSectionElement
*/
export default class HTMLTableSectionElement extends HTMLElement {
/**
* Returns an HTMLTableRowElement representing a new row of the table. It inserts it in the rows collection immediately before the <tr> element at the given index position. If the index is -1, the new row is appended to the collection. If the index is smaller than -1 or greater than the number of rows in the collection, a DOMException with the value IndexSizeError is raised.
*
* @param [index] Index.
* @returns Row.
*/
insertRow(index?: number): HTMLTableRowElement;
/**
* Removes the row corresponding to the index given in parameter. If the index value is -1 the last row is removed; if it is smaller than -1 or greater than the amount of rows in the collection, a DOMException with the value IndexSizeError is raised.
*
* @param index Index.
*/
deleteRow(index: number): void;
}
//# sourceMappingURL=HTMLTableSectionElement.d.ts.map

View File

@@ -0,0 +1 @@
{"version":3,"file":"HTMLTableSectionElement.d.ts","sourceRoot":"","sources":["../../../src/nodes/html-table-section-element/HTMLTableSectionElement.ts"],"names":[],"mappings":"AAEA,OAAO,WAAW,MAAM,gCAAgC,CAAC;AACzD,OAAO,mBAAmB,MAAM,kDAAkD,CAAC;AAEnF;;;;GAIG;AACH,MAAM,CAAC,OAAO,OAAO,uBAAwB,SAAQ,WAAW;IAC/D;;;;;OAKG;IACI,SAAS,CAAC,KAAK,GAAE,MAAW,GAAG,mBAAmB;IAgCzD;;;;OAIG;IACI,SAAS,CAAC,KAAK,EAAE,MAAM,GAAG,IAAI;CAiCrC"}

View File

@@ -0,0 +1,62 @@
import QuerySelector from '../../query-selector/QuerySelector.js';
import * as PropertySymbol from '../../PropertySymbol.js';
import HTMLElement from '../html-element/HTMLElement.js';
import DOMExceptionNameEnum from '../../exception/DOMExceptionNameEnum.js';
/**
* HTMLTableSectionElement
*
* @see https://developer.mozilla.org/en-US/docs/Web/API/HTMLTableSectionElement
*/
export default class HTMLTableSectionElement extends HTMLElement {
/**
* Returns an HTMLTableRowElement representing a new row of the table. It inserts it in the rows collection immediately before the <tr> element at the given index position. If the index is -1, the new row is appended to the collection. If the index is smaller than -1 or greater than the number of rows in the collection, a DOMException with the value IndexSizeError is raised.
*
* @param [index] Index.
* @returns Row.
*/
insertRow(index = -1) {
if (typeof index !== 'number') {
index = -1;
}
const rows = QuerySelector.querySelectorAll(this, 'tr')[PropertySymbol.items];
if (index < -1) {
throw new this[PropertySymbol.window].DOMException(`Failed to execute 'insertRow' on 'HTMLTableSectionElement': The index provided (${index}) is less than -1.`, DOMExceptionNameEnum.indexSizeError);
}
if (index > rows.length) {
throw new this[PropertySymbol.window].DOMException(`Failed to execute 'insertRow' on 'HTMLTableSectionElement': The index provided (${index}) is greater than the number of rows (${rows.length}).`, DOMExceptionNameEnum.indexSizeError);
}
const row = this[PropertySymbol.ownerDocument].createElement('tr');
if (index === -1 || index === rows.length) {
this.appendChild(row);
}
else {
this.insertBefore(row, rows[index]);
}
return row;
}
/**
* Removes the row corresponding to the index given in parameter. If the index value is -1 the last row is removed; if it is smaller than -1 or greater than the amount of rows in the collection, a DOMException with the value IndexSizeError is raised.
*
* @param index Index.
*/
deleteRow(index) {
if (arguments.length === 0) {
throw new this[PropertySymbol.window].TypeError("Failed to execute 'deleteRow' on 'HTMLTableSectionElement': 1 argument required, but only 0 present.");
}
if (typeof index !== 'number') {
index = -1;
}
if (index < -1) {
throw new this[PropertySymbol.window].DOMException(`Failed to execute 'deleteRow' on 'HTMLTableSectionElement': The index provided (${index}) is less than -1.`, DOMExceptionNameEnum.indexSizeError);
}
const rows = QuerySelector.querySelectorAll(this, 'tr')[PropertySymbol.items];
if (index >= rows.length) {
throw new this[PropertySymbol.window].DOMException(`Failed to execute 'deleteRow' on 'HTMLTableSectionElement': The index provided (${index}) is greater than the number of rows in the table (${rows.length}).`, DOMExceptionNameEnum.indexSizeError);
}
if (index === -1) {
index = rows.length - 1;
}
rows[index].remove();
}
}
//# sourceMappingURL=HTMLTableSectionElement.js.map

View File

@@ -0,0 +1 @@
{"version":3,"file":"HTMLTableSectionElement.js","sourceRoot":"","sources":["../../../src/nodes/html-table-section-element/HTMLTableSectionElement.ts"],"names":[],"mappings":"AAAA,OAAO,aAAa,MAAM,uCAAuC,CAAC;AAClE,OAAO,KAAK,cAAc,MAAM,yBAAyB,CAAC;AAC1D,OAAO,WAAW,MAAM,gCAAgC,CAAC;AAEzD,OAAO,oBAAoB,MAAM,yCAAyC,CAAC;AAC3E;;;;GAIG;AACH,MAAM,CAAC,OAAO,OAAO,uBAAwB,SAAQ,WAAW;IAC/D;;;;;OAKG;IACI,SAAS,CAAC,QAAgB,CAAC,CAAC;QAClC,IAAI,OAAO,KAAK,KAAK,QAAQ,EAAE,CAAC;YAC/B,KAAK,GAAG,CAAC,CAAC,CAAC;QACZ,CAAC;QAED,MAAM,IAAI,GAAG,aAAa,CAAC,gBAAgB,CAAC,IAAI,EAAE,IAAI,CAAC,CAAC,cAAc,CAAC,KAAK,CAAC,CAAC;QAE9E,IAAI,KAAK,GAAG,CAAC,CAAC,EAAE,CAAC;YAChB,MAAM,IAAI,IAAI,CAAC,cAAc,CAAC,MAAM,CAAC,CAAC,YAAY,CACjD,mFAAmF,KAAK,oBAAoB,EAC5G,oBAAoB,CAAC,cAAc,CACnC,CAAC;QACH,CAAC;QAED,IAAI,KAAK,GAAG,IAAI,CAAC,MAAM,EAAE,CAAC;YAC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