Compare commits
8 Commits
frontend/t
...
4c3ed8a76c
| Author | SHA1 | Date | |
|---|---|---|---|
| 4c3ed8a76c | |||
| adb61cbc13 | |||
| be0f7b728e | |||
| 0aac1bd734 | |||
| 5fcfd3e381 | |||
| b7f89b4e58 | |||
| 531cb007bd | |||
| 2c0568639c |
34
AGENTS.linux.md
Normal file
@@ -0,0 +1,34 @@
|
|||||||
|
# Agent Guide
|
||||||
|
|
||||||
|
Also see the other related technical documentation in the docs folder.
|
||||||
|
|
||||||
|
## Tools
|
||||||
|
|
||||||
|
These tools are installed and available: Python3, MiKTeX, Tesseract, Playwright
|
||||||
|
|
||||||
|
## Rules
|
||||||
|
|
||||||
|
- Prefer extracting code to a shared helper to be reused instead of duplicating code. Always keep high maintainability standards.
|
||||||
|
- Always place each newly created class into its own file. The file name must match the class name.
|
||||||
|
- When asked to begin working on a task, create a detailed implementation plan first, present the plan to the user, and ask for approval before beginning with the actual implementation.
|
||||||
|
- Don't make assumptions in the plan. If necessary, ask all clarifying questions before presenting the final plan.
|
||||||
|
- When an task is finished, perform a code review to evaluate if the change is clean and maintainable with high software engineering standards. Iterate on the code and repeat the review process until satisfied.
|
||||||
|
- If there's documnentation present, always keep it updated.
|
||||||
|
- After every iteration, evaluate if the test coverage would fall below 100%, and write tests if necessary.
|
||||||
|
- After every iteration, run `dotnet jb cleanupcode --build=False '$file1' '$file2' ...` for every file you touched.
|
||||||
|
- After every frontend change, verify the results using an ephemeral Playwright run.
|
||||||
|
- For ad hoc verification in this repo, do not default to `npx playwright test` with a temp spec outside the repo.
|
||||||
|
- When browser verification needs the app running, launch the app against a temporary copy of `src\RolemasterDb.App\rolemaster.db` so verification does not mutate the canonical DB.
|
||||||
|
### Git
|
||||||
|
|
||||||
|
- Never change the .gitignore file without consent.
|
||||||
|
- Keep changes small with minimal churn and commit often. If one iteration encompasses many smaller tasks with more than one commit, create a git branch and do the commits there. Let me review the branch before merging it back to master.
|
||||||
|
- When multiple commits are necessary, pause after every commit and ask the user to give a command to proceed.
|
||||||
|
- After every iteration, do a git commit with a brief summary of the changes as a commit message.
|
||||||
|
- If you find unexpected changes in the code (deletions, changes, diff results that were not communicated), never revert them and never restore the old state. Assume that those changes happened with intent.
|
||||||
|
- Never use `git restore`, `git checkout --`, reset commands, or equivalent rollback actions to discard local changes unless the user explicitly asks for that exact rollback.
|
||||||
|
|
||||||
|
### Dotnet CLI
|
||||||
|
|
||||||
|
- If you need a separate output directory, use a subfolder under `artifacts`, and clean it up afterwards.
|
||||||
|
- Avoid running `dotnet build` and `dotnet test` in parallel in this repo; that can cause file-lock failures in `obj\Debug\net10.0`.
|
||||||
56
AGENTS.md
@@ -1,55 +1 @@
|
|||||||
# Agent Guide
|
This is a linux environment, read `AGENTS.linux.md`.
|
||||||
|
|
||||||
Also see the other related technical documentation in the docs folder.
|
|
||||||
|
|
||||||
## Tools
|
|
||||||
|
|
||||||
These tool paths should be used instead of any entry in the PATH environment variable:
|
|
||||||
|
|
||||||
- Python is installed in `C:\Users\frank\AppData\Local\Programs\Python\Python314`.
|
|
||||||
- MiKTeX portable is installed in `D:\Code\miktex-portable\texmfs\install\miktex\bin\x64`.
|
|
||||||
- Tesseract is installed in `C:\Program Files\Sejda PDF Desktop\resources\vendor\tesseract-windows-x64`.
|
|
||||||
|
|
||||||
## Rules
|
|
||||||
|
|
||||||
- Prefer extracting code to a shared helper to be reused instead of duplicating code. Always keep high maintainability standards.
|
|
||||||
- Keep changes as small as possible, design solutions that achieve the goals with minimal churn.
|
|
||||||
- Always place each newly created class into its own file. The file name must match the class name.
|
|
||||||
- When asked to begin working on a task, create a detailed implementation plan first, present the plan to the user, and ask for approval before beginning with the actual implementation.
|
|
||||||
- Don't make assumptions in the plan. If necessary, ask all clarifying questions before presenting the final plan.
|
|
||||||
- When an task is finished, perform a code review to evaluate if the change is clean and maintainable with high software engineering standards. Iterate on the code and repeat the review process until satisfied.
|
|
||||||
- After the implementation is finished, verify all changed files, and run `python D:\Code\crlf.py $file1 $file2 ...` only for files you recognize, in order to normalize all line endings of all touched files to CRLF.
|
|
||||||
- If there's documnentation present, always keep it updated.
|
|
||||||
- After every iteration, evaluate if the test coverage would fall below 100%, and write tests if necessary.
|
|
||||||
- After every iteration, run `jb cleanupcode --build=False '$file1' '$file2' ...` for every file you touched.
|
|
||||||
- After every frontend change, verify the results using an ephemeral Playwright run.
|
|
||||||
- For ad hoc verification in this repo, do not default to `npx playwright test` with a temp spec outside the repo.
|
|
||||||
- Prefer a repo-local ephemeral Node script under `artifacts_verify/` that imports `playwright` with `require('playwright')` and drives the browser directly.
|
|
||||||
- If using the Playwright test runner, use the repo-local CLI at `node_modules\.bin\playwright.cmd` and keep the spec inside the repo so local `node_modules` resolution works.
|
|
||||||
- Do not mix the global Playwright CLI with the repo-local `@playwright/test` package.
|
|
||||||
- When browser verification needs the app running, launch the app against a temporary copy of `src\RolemasterDb.App\rolemaster.db` so verification does not mutate the canonical DB.
|
|
||||||
### Git
|
|
||||||
|
|
||||||
- Never change the .gitignore file without consent.
|
|
||||||
- Keep changes small and commit often. If one iteration encompasses many smaller tasks with more than one commit, create a git branch and do the commits there. Let me review the branch before merging it back to master.
|
|
||||||
- When multiple commits are necessary, pause after every commit and ask the user to give a command to proceed.
|
|
||||||
- After every iteration, do a git commit with a brief summary of the changes as a commit message.
|
|
||||||
- If you find unexpected changes in the code (deletions, changes, diff results that were not communicated), never revert them and never restore the old state. Assume that those changes happened with intent.
|
|
||||||
- Never use `git restore`, `git checkout --`, reset commands, or equivalent rollback actions to discard local changes unless the user explicitly asks for that exact rollback.
|
|
||||||
|
|
||||||
### PowerShell
|
|
||||||
|
|
||||||
- This is a Windows environment, WSL is not installed (i.e. sed is not available). You're running under PowerShell 7.5.5. Due to platform restrictions, file deletions are not possible. Replacing the entire file content via a context diff is a viable alternative.
|
|
||||||
- PowerShell doesn't support bash-style heredocs. If complex scripts need to be executed, consider using python as a last resort. Run Python code using python -c with inline commands instead of python - <<'PY'.
|
|
||||||
- Parallel PowerShell calls are flaky, stick to sequential reads and command execution.
|
|
||||||
- Commands like `rg` and `Get-Content` are always allowed.
|
|
||||||
|
|
||||||
### Dotnet CLI
|
|
||||||
|
|
||||||
- If a build fails with 0 errors / 0 warnings:
|
|
||||||
- Do not keep retrying the same build command
|
|
||||||
- Consider using --no-restore.
|
|
||||||
- Consider using `$env:DOTNET_SKIP_FIRST_TIME_EXPERIENCE = '1'`
|
|
||||||
- Consider using `$env:NUGET_PACKAGES = Join-Path $env:USERPROFILE '.nuget\packages'`
|
|
||||||
- If you need a separate output directory, use a subfolder under `artifacts`, and clean it up afterwards.
|
|
||||||
- Avoid running `dotnet build` and `dotnet test` in parallel in this repo; that can cause file-lock failures in `obj\Debug\net10.0`.
|
|
||||||
55
AGENTS.windows.md
Normal file
@@ -0,0 +1,55 @@
|
|||||||
|
# Agent Guide
|
||||||
|
|
||||||
|
Also see the other related technical documentation in the docs folder.
|
||||||
|
|
||||||
|
## Tools
|
||||||
|
|
||||||
|
These tool paths should be used instead of any entry in the PATH environment variable:
|
||||||
|
|
||||||
|
- Python is installed in `C:\Users\frank\AppData\Local\Programs\Python\Python314`.
|
||||||
|
- MiKTeX portable is installed in `D:\Code\miktex-portable\texmfs\install\miktex\bin\x64`.
|
||||||
|
- Tesseract is installed in `C:\Program Files\Sejda PDF Desktop\resources\vendor\tesseract-windows-x64`.
|
||||||
|
|
||||||
|
## Rules
|
||||||
|
|
||||||
|
- Prefer extracting code to a shared helper to be reused instead of duplicating code. Always keep high maintainability standards.
|
||||||
|
- Keep changes as small as possible, design solutions that achieve the goals with minimal churn.
|
||||||
|
- Always place each newly created class into its own file. The file name must match the class name.
|
||||||
|
- When asked to begin working on a task, create a detailed implementation plan first, present the plan to the user, and ask for approval before beginning with the actual implementation.
|
||||||
|
- Don't make assumptions in the plan. If necessary, ask all clarifying questions before presenting the final plan.
|
||||||
|
- When an task is finished, perform a code review to evaluate if the change is clean and maintainable with high software engineering standards. Iterate on the code and repeat the review process until satisfied.
|
||||||
|
- After the implementation is finished, verify all changed files, and run `python D:\Code\crlf.py $file1 $file2 ...` only for files you recognize, in order to normalize all line endings of all touched files to CRLF.
|
||||||
|
- If there's documnentation present, always keep it updated.
|
||||||
|
- After every iteration, evaluate if the test coverage would fall below 100%, and write tests if necessary.
|
||||||
|
- After every iteration, run `jb cleanupcode --build=False '$file1' '$file2' ...` for every file you touched.
|
||||||
|
- After every frontend change, verify the results using an ephemeral Playwright run.
|
||||||
|
- For ad hoc verification in this repo, do not default to `npx playwright test` with a temp spec outside the repo.
|
||||||
|
- Prefer a repo-local ephemeral Node script under `artifacts_verify/` that imports `playwright` with `require('playwright')` and drives the browser directly.
|
||||||
|
- If using the Playwright test runner, use the repo-local CLI at `node_modules\.bin\playwright.cmd` and keep the spec inside the repo so local `node_modules` resolution works.
|
||||||
|
- Do not mix the global Playwright CLI with the repo-local `@playwright/test` package.
|
||||||
|
- When browser verification needs the app running, launch the app against a temporary copy of `src\RolemasterDb.App\rolemaster.db` so verification does not mutate the canonical DB.
|
||||||
|
### Git
|
||||||
|
|
||||||
|
- Never change the .gitignore file without consent.
|
||||||
|
- Keep changes small and commit often. If one iteration encompasses many smaller tasks with more than one commit, create a git branch and do the commits there. Let me review the branch before merging it back to master.
|
||||||
|
- When multiple commits are necessary, pause after every commit and ask the user to give a command to proceed.
|
||||||
|
- After every iteration, do a git commit with a brief summary of the changes as a commit message.
|
||||||
|
- If you find unexpected changes in the code (deletions, changes, diff results that were not communicated), never revert them and never restore the old state. Assume that those changes happened with intent.
|
||||||
|
- Never use `git restore`, `git checkout --`, reset commands, or equivalent rollback actions to discard local changes unless the user explicitly asks for that exact rollback.
|
||||||
|
|
||||||
|
### PowerShell
|
||||||
|
|
||||||
|
- This is a Windows environment, WSL is not installed (i.e. sed is not available). You're running under PowerShell 7.5.5. Due to platform restrictions, file deletions are not possible. Replacing the entire file content via a context diff is a viable alternative.
|
||||||
|
- PowerShell doesn't support bash-style heredocs. If complex scripts need to be executed, consider using python as a last resort. Run Python code using python -c with inline commands instead of python - <<'PY'.
|
||||||
|
- Parallel PowerShell calls are flaky, stick to sequential reads and command execution.
|
||||||
|
- Commands like `rg` and `Get-Content` are always allowed.
|
||||||
|
|
||||||
|
### Dotnet CLI
|
||||||
|
|
||||||
|
- If a build fails with 0 errors / 0 warnings:
|
||||||
|
- Do not keep retrying the same build command
|
||||||
|
- Consider using --no-restore.
|
||||||
|
- Consider using `$env:DOTNET_SKIP_FIRST_TIME_EXPERIENCE = '1'`
|
||||||
|
- Consider using `$env:NUGET_PACKAGES = Join-Path $env:USERPROFILE '.nuget\packages'`
|
||||||
|
- If you need a separate output directory, use a subfolder under `artifacts`, and clean it up afterwards.
|
||||||
|
- Avoid running `dotnet build` and `dotnet test` in parallel in this repo; that can cause file-lock failures in `obj\Debug\net10.0`.
|
||||||
@@ -13,6 +13,8 @@ The tool is intentionally separate from the web application startup path. Critic
|
|||||||
|
|
||||||
The tool currently lives in `src/RolemasterDb.ImportTool` and operates against the same SQLite schema used by the web app.
|
The tool currently lives in `src/RolemasterDb.ImportTool` and operates against the same SQLite schema used by the web app.
|
||||||
|
|
||||||
|
For the committed app database workflow, the web app forces SQLite `journal_mode=DELETE` during startup so local curation changes land in `src/RolemasterDb.App/rolemaster.db` directly instead of accumulating in a long-lived WAL sidecar.
|
||||||
|
|
||||||
## Goals
|
## Goals
|
||||||
|
|
||||||
The importer is designed around the following requirements:
|
The importer is designed around the following requirements:
|
||||||
@@ -70,7 +72,7 @@ The current implementation supports:
|
|||||||
|
|
||||||
The current implementation does not yet support:
|
The current implementation does not yet support:
|
||||||
|
|
||||||
- OCR/image-based PDFs such as `Void.pdf`
|
- full OCR bootstrap on machines where Tesseract language data is unavailable
|
||||||
- automatic confidence scoring beyond validation errors
|
- automatic confidence scoring beyond validation errors
|
||||||
|
|
||||||
## High-Level Architecture
|
## High-Level Architecture
|
||||||
@@ -381,15 +383,18 @@ Example:
|
|||||||
dotnet run --project .\src\RolemasterDb.ImportTool\RolemasterDb.ImportTool.csproj -- import slash
|
dotnet run --project .\src\RolemasterDb.ImportTool\RolemasterDb.ImportTool.csproj -- import slash
|
||||||
```
|
```
|
||||||
|
|
||||||
### `reimport-images <table>`
|
### `reimport-images [table]`
|
||||||
|
|
||||||
Reuses `source.xml`, regenerates page PNGs and cell PNGs, rewrites the JSON artifacts, and refreshes only source-image metadata in SQLite.
|
Reuses the extracted source artifact, regenerates page PNGs and cell PNGs, rewrites the JSON artifacts, and optionally refreshes source-image metadata in SQLite.
|
||||||
|
|
||||||
|
For OCR-backed tables, `--update-metadata false` also enables a database-provenance fallback: if the OCR source artifact cannot be regenerated in the current environment, the command can still repopulate the committed page and cell PNGs from the existing `SourceImagePath` and `SourceImageCropJson` values stored in SQLite.
|
||||||
|
|
||||||
Use this when:
|
Use this when:
|
||||||
|
|
||||||
- crop resolution or render settings changed
|
- crop resolution or render settings changed
|
||||||
- you want better source images without reloading result text
|
- you want better source images without reloading result text
|
||||||
- you want to keep curated and uncurated content untouched while refreshing artifacts
|
- you want to keep curated and uncurated content untouched while refreshing artifacts
|
||||||
|
- you need to repopulate the committed artifact tree without touching the database
|
||||||
|
|
||||||
Example:
|
Example:
|
||||||
|
|
||||||
@@ -397,6 +402,19 @@ Example:
|
|||||||
dotnet run --project .\src\RolemasterDb.ImportTool\RolemasterDb.ImportTool.csproj -- reimport-images slash
|
dotnet run --project .\src\RolemasterDb.ImportTool\RolemasterDb.ImportTool.csproj -- reimport-images slash
|
||||||
```
|
```
|
||||||
|
|
||||||
|
Refresh all enabled manifest entries without modifying SQLite metadata:
|
||||||
|
|
||||||
|
```powershell
|
||||||
|
dotnet run --project .\src\RolemasterDb.ImportTool\RolemasterDb.ImportTool.csproj -- reimport-images --all --update-metadata false
|
||||||
|
```
|
||||||
|
|
||||||
|
Command options:
|
||||||
|
|
||||||
|
- pass a table slug to refresh one enabled manifest entry
|
||||||
|
- pass `--all` to refresh every enabled manifest entry
|
||||||
|
- `--update-metadata` defaults to `true`; set it to `false` when you only want to regenerate committed artifacts
|
||||||
|
- when `--update-metadata false` is used, OCR tables may fall back to existing SQLite source-image metadata to regenerate page and cell PNGs without changing the database
|
||||||
|
|
||||||
## Manifest
|
## Manifest
|
||||||
|
|
||||||
The importer manifest is stored at:
|
The importer manifest is stored at:
|
||||||
@@ -425,7 +443,7 @@ For the currently enabled entries:
|
|||||||
|
|
||||||
Artifacts are written under:
|
Artifacts are written under:
|
||||||
|
|
||||||
- `artifacts/import/critical/<slug>/`
|
- `src/RolemasterDb.App/import-artifacts/critical/<slug>/`
|
||||||
|
|
||||||
The current artifact set is:
|
The current artifact set is:
|
||||||
|
|
||||||
|
|||||||
13
dotnet-tools.json
Normal file
@@ -0,0 +1,13 @@
|
|||||||
|
{
|
||||||
|
"version": 1,
|
||||||
|
"isRoot": true,
|
||||||
|
"tools": {
|
||||||
|
"jetbrains.resharper.globaltools": {
|
||||||
|
"version": "2026.1.0.1",
|
||||||
|
"commands": [
|
||||||
|
"jb"
|
||||||
|
],
|
||||||
|
"rollForward": false
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -1,9 +1,8 @@
|
|||||||
#blazor-error-ui {
|
#blazor-error-ui {
|
||||||
color-scheme: light only;
|
background: color-mix(in srgb, var(--surface-danger-banner) 88%, var(--bg-elevated));
|
||||||
background: #682e24;
|
color: var(--text-on-danger);
|
||||||
color: #fffaf2;
|
|
||||||
bottom: 0;
|
bottom: 0;
|
||||||
box-shadow: 0 -1px 12px rgba(0, 0, 0, 0.22);
|
box-shadow: 0 -1px 12px color-mix(in srgb, var(--shadow-strong) 72%, transparent);
|
||||||
box-sizing: border-box;
|
box-sizing: border-box;
|
||||||
display: none;
|
display: none;
|
||||||
left: 0;
|
left: 0;
|
||||||
@@ -14,6 +13,7 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
#blazor-error-ui .dismiss {
|
#blazor-error-ui .dismiss {
|
||||||
|
color: inherit;
|
||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
position: absolute;
|
position: absolute;
|
||||||
right: 0.75rem;
|
right: 0.75rem;
|
||||||
|
|||||||
@@ -21,13 +21,14 @@
|
|||||||
|
|
||||||
|
|
||||||
#components-reconnect-modal {
|
#components-reconnect-modal {
|
||||||
background-color: white;
|
background-color: color-mix(in srgb, var(--surface-card-strong) 96%, var(--bg-elevated));
|
||||||
|
color: var(--text-primary);
|
||||||
width: 20rem;
|
width: 20rem;
|
||||||
margin: 20vh auto;
|
margin: 20vh auto;
|
||||||
padding: 2rem;
|
padding: 2rem;
|
||||||
border: 0;
|
border: 1px solid var(--border-default);
|
||||||
border-radius: 0.5rem;
|
border-radius: 0.5rem;
|
||||||
box-shadow: 0 3px 6px 2px rgba(0, 0, 0, 0.3);
|
box-shadow: var(--shadow-2);
|
||||||
opacity: 0;
|
opacity: 0;
|
||||||
transition: display 0.5s allow-discrete, overlay 0.5s allow-discrete;
|
transition: display 0.5s allow-discrete, overlay 0.5s allow-discrete;
|
||||||
animation: components-reconnect-modal-fadeOutOpacity 0.5s both;
|
animation: components-reconnect-modal-fadeOutOpacity 0.5s both;
|
||||||
@@ -41,7 +42,7 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
#components-reconnect-modal::backdrop {
|
#components-reconnect-modal::backdrop {
|
||||||
background-color: rgba(0, 0, 0, 0.4);
|
background-color: var(--bg-overlay);
|
||||||
animation: components-reconnect-modal-fadeInOpacity 0.5s ease-in-out;
|
animation: components-reconnect-modal-fadeInOpacity 0.5s ease-in-out;
|
||||||
opacity: 1;
|
opacity: 1;
|
||||||
}
|
}
|
||||||
@@ -90,18 +91,18 @@
|
|||||||
|
|
||||||
#components-reconnect-modal button {
|
#components-reconnect-modal button {
|
||||||
border: 0;
|
border: 0;
|
||||||
background-color: #6b9ed2;
|
background: linear-gradient(135deg, var(--accent-4), var(--accent-5));
|
||||||
color: white;
|
color: var(--text-on-accent);
|
||||||
padding: 4px 24px;
|
padding: 4px 24px;
|
||||||
border-radius: 4px;
|
border-radius: 4px;
|
||||||
}
|
}
|
||||||
|
|
||||||
#components-reconnect-modal button:hover {
|
#components-reconnect-modal button:hover {
|
||||||
background-color: #3b6ea2;
|
background: linear-gradient(135deg, color-mix(in srgb, var(--accent-4) 88%, var(--accent-2)), var(--accent-5));
|
||||||
}
|
}
|
||||||
|
|
||||||
#components-reconnect-modal button:active {
|
#components-reconnect-modal button:active {
|
||||||
background-color: #6b9ed2;
|
background: linear-gradient(135deg, var(--accent-4), var(--accent-5));
|
||||||
}
|
}
|
||||||
|
|
||||||
.components-rejoining-animation {
|
.components-rejoining-animation {
|
||||||
@@ -112,7 +113,7 @@
|
|||||||
|
|
||||||
.components-rejoining-animation div {
|
.components-rejoining-animation div {
|
||||||
position: absolute;
|
position: absolute;
|
||||||
border: 3px solid #0087ff;
|
border: 3px solid var(--info-5);
|
||||||
opacity: 1;
|
opacity: 1;
|
||||||
border-radius: 50%;
|
border-radius: 50%;
|
||||||
animation: components-rejoining-animation 1.5s cubic-bezier(0, 0.2, 0.8, 1) infinite;
|
animation: components-rejoining-animation 1.5s cubic-bezier(0, 0.2, 0.8, 1) infinite;
|
||||||
|
|||||||
@@ -74,7 +74,7 @@
|
|||||||
font-size: 0.85rem;
|
font-size: 0.85rem;
|
||||||
letter-spacing: 0.12em;
|
letter-spacing: 0.12em;
|
||||||
text-transform: uppercase;
|
text-transform: uppercase;
|
||||||
box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.22);
|
box-shadow: inset 0 1px 0 color-mix(in srgb, var(--text-on-accent) 22%, transparent);
|
||||||
}
|
}
|
||||||
|
|
||||||
.app-shell-brand-copy {
|
.app-shell-brand-copy {
|
||||||
|
|||||||
@@ -33,7 +33,7 @@
|
|||||||
color: var(--text-primary);
|
color: var(--text-primary);
|
||||||
background: color-mix(in srgb, var(--accent-1) 84%, var(--surface-2));
|
background: color-mix(in srgb, var(--accent-1) 84%, var(--surface-2));
|
||||||
border-color: color-mix(in srgb, var(--accent-3) 45%, var(--border-default));
|
border-color: color-mix(in srgb, var(--accent-3) 45%, var(--border-default));
|
||||||
box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.16);
|
box-shadow: inset 0 1px 0 color-mix(in srgb, var(--text-on-accent) 16%, transparent);
|
||||||
}
|
}
|
||||||
|
|
||||||
.shell-primary-nav-link.is-tools-link {
|
.shell-primary-nav-link.is-tools-link {
|
||||||
|
|||||||
@@ -11,6 +11,7 @@ public static class RolemasterDbInitializer
|
|||||||
await using var dbContext = await dbFactory.CreateDbContextAsync(cancellationToken);
|
await using var dbContext = await dbFactory.CreateDbContextAsync(cancellationToken);
|
||||||
|
|
||||||
await dbContext.Database.EnsureCreatedAsync(cancellationToken);
|
await dbContext.Database.EnsureCreatedAsync(cancellationToken);
|
||||||
|
await EnsureDeleteJournalModeAsync(dbContext, cancellationToken);
|
||||||
await RolemasterDbSchemaUpgrader.EnsureLatestAsync(dbContext, cancellationToken);
|
await RolemasterDbSchemaUpgrader.EnsureLatestAsync(dbContext, cancellationToken);
|
||||||
RolemasterSeedData.BackfillAttackTableMetadata(dbContext);
|
RolemasterSeedData.BackfillAttackTableMetadata(dbContext);
|
||||||
|
|
||||||
@@ -23,4 +24,18 @@ public static class RolemasterDbInitializer
|
|||||||
RolemasterSeedData.SeedAttackStarterData(dbContext);
|
RolemasterSeedData.SeedAttackStarterData(dbContext);
|
||||||
await dbContext.SaveChangesAsync(cancellationToken);
|
await dbContext.SaveChangesAsync(cancellationToken);
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
private static async Task EnsureDeleteJournalModeAsync(RolemasterDbContext dbContext,
|
||||||
|
CancellationToken cancellationToken)
|
||||||
|
{
|
||||||
|
await dbContext.Database.OpenConnectionAsync(cancellationToken);
|
||||||
|
await using var command = dbContext.Database.GetDbConnection().CreateCommand();
|
||||||
|
command.CommandText = "PRAGMA journal_mode=DELETE;";
|
||||||
|
|
||||||
|
var result = await command.ExecuteScalarAsync(cancellationToken);
|
||||||
|
if (!string.Equals(Convert.ToString(result), "delete", StringComparison.OrdinalIgnoreCase))
|
||||||
|
{
|
||||||
|
throw new InvalidOperationException("Failed to configure SQLite journal_mode=DELETE.");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -33,12 +33,12 @@ public sealed class CriticalImportArtifactLocator
|
|||||||
{
|
{
|
||||||
if (File.Exists(Path.Combine(probe.FullName, "RolemasterDB.slnx")))
|
if (File.Exists(Path.Combine(probe.FullName, "RolemasterDB.slnx")))
|
||||||
{
|
{
|
||||||
return Path.Combine(probe.FullName, "artifacts", "import", "critical");
|
return Path.Combine(probe.FullName, "src", "RolemasterDb.App", "import-artifacts", "critical");
|
||||||
}
|
}
|
||||||
|
|
||||||
probe = probe.Parent;
|
probe = probe.Parent;
|
||||||
}
|
}
|
||||||
|
|
||||||
return Path.Combine(contentRootPath, "artifacts", "import", "critical");
|
return Path.Combine(contentRootPath, "import-artifacts", "critical");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
After Width: | Height: | Size: 5.3 KiB |
|
After Width: | Height: | Size: 11 KiB |
|
After Width: | Height: | Size: 26 KiB |
|
After Width: | Height: | Size: 14 KiB |
|
After Width: | Height: | Size: 14 KiB |
|
After Width: | Height: | Size: 14 KiB |
|
After Width: | Height: | Size: 16 KiB |
|
After Width: | Height: | Size: 14 KiB |
|
After Width: | Height: | Size: 12 KiB |
|
After Width: | Height: | Size: 13 KiB |
|
After Width: | Height: | Size: 19 KiB |
|
After Width: | Height: | Size: 19 KiB |
|
After Width: | Height: | Size: 22 KiB |
|
After Width: | Height: | Size: 22 KiB |
|
After Width: | Height: | Size: 25 KiB |
|
After Width: | Height: | Size: 21 KiB |
|
After Width: | Height: | Size: 22 KiB |
|
After Width: | Height: | Size: 25 KiB |
|
After Width: | Height: | Size: 30 KiB |
|
After Width: | Height: | Size: 11 KiB |
|
After Width: | Height: | Size: 5.7 KiB |
|
After Width: | Height: | Size: 19 KiB |
|
After Width: | Height: | Size: 13 KiB |
|
After Width: | Height: | Size: 16 KiB |
|
After Width: | Height: | Size: 7.6 KiB |
|
After Width: | Height: | Size: 20 KiB |
|
After Width: | Height: | Size: 14 KiB |
|
After Width: | Height: | Size: 13 KiB |
|
After Width: | Height: | Size: 30 KiB |
|
After Width: | Height: | Size: 26 KiB |
|
After Width: | Height: | Size: 22 KiB |
|
After Width: | Height: | Size: 16 KiB |
|
After Width: | Height: | Size: 25 KiB |
|
After Width: | Height: | Size: 26 KiB |
|
After Width: | Height: | Size: 22 KiB |
|
After Width: | Height: | Size: 20 KiB |
|
After Width: | Height: | Size: 25 KiB |
|
After Width: | Height: | Size: 24 KiB |
|
After Width: | Height: | Size: 10 KiB |
|
After Width: | Height: | Size: 12 KiB |
|
After Width: | Height: | Size: 17 KiB |
|
After Width: | Height: | Size: 7.7 KiB |
|
After Width: | Height: | Size: 16 KiB |
|
After Width: | Height: | Size: 15 KiB |
|
After Width: | Height: | Size: 13 KiB |
|
After Width: | Height: | Size: 10 KiB |
|
After Width: | Height: | Size: 12 KiB |
|
After Width: | Height: | Size: 24 KiB |
|
After Width: | Height: | Size: 22 KiB |
|
After Width: | Height: | Size: 18 KiB |
|
After Width: | Height: | Size: 18 KiB |
|
After Width: | Height: | Size: 23 KiB |
|
After Width: | Height: | Size: 24 KiB |
|
After Width: | Height: | Size: 22 KiB |
|
After Width: | Height: | Size: 16 KiB |
|
After Width: | Height: | Size: 39 KiB |
|
After Width: | Height: | Size: 31 KiB |
|
After Width: | Height: | Size: 8.2 KiB |
|
After Width: | Height: | Size: 9.0 KiB |
|
After Width: | Height: | Size: 19 KiB |
|
After Width: | Height: | Size: 8.8 KiB |
|
After Width: | Height: | Size: 12 KiB |
|
After Width: | Height: | Size: 8.8 KiB |
|
After Width: | Height: | Size: 22 KiB |
|
After Width: | Height: | Size: 19 KiB |
|
After Width: | Height: | Size: 17 KiB |
|
After Width: | Height: | Size: 14 KiB |
|
After Width: | Height: | Size: 32 KiB |
|
After Width: | Height: | Size: 16 KiB |
|
After Width: | Height: | Size: 22 KiB |
|
After Width: | Height: | Size: 24 KiB |
|
After Width: | Height: | Size: 19 KiB |
|
After Width: | Height: | Size: 25 KiB |
|
After Width: | Height: | Size: 22 KiB |
|
After Width: | Height: | Size: 37 KiB |
|
After Width: | Height: | Size: 26 KiB |
|
After Width: | Height: | Size: 5.7 KiB |
|
After Width: | Height: | Size: 12 KiB |
|
After Width: | Height: | Size: 14 KiB |
|
After Width: | Height: | Size: 8.7 KiB |
|
After Width: | Height: | Size: 16 KiB |
|
After Width: | Height: | Size: 12 KiB |
|
After Width: | Height: | Size: 16 KiB |
|
After Width: | Height: | Size: 25 KiB |
|
After Width: | Height: | Size: 18 KiB |
|
After Width: | Height: | Size: 19 KiB |
|
After Width: | Height: | Size: 24 KiB |
|
After Width: | Height: | Size: 18 KiB |
|
After Width: | Height: | Size: 27 KiB |