Compare commits
5 Commits
ac4ff5cd19
...
8e91cb26d7
| Author | SHA1 | Date | |
|---|---|---|---|
| 8e91cb26d7 | |||
| 3b76070394 | |||
| fc39c8d4bf | |||
| 26d1855365 | |||
| 6a31bc3737 |
@@ -452,7 +452,30 @@ Before writing code, verify:
|
||||
- **Non-value-loss sell:** Requires ReentryWatch, new CycleId/Lot, step intervals, expiry, dedup.
|
||||
- **Activation gating:** Requires ModelCard, OOS/PBO/DSR evidence, maker-checker approval, effective_at, rollback justification.
|
||||
|
||||
## Gitea API Automation (Optional but Recommended)
|
||||
## Gitea API Automation & Actions Secrets
|
||||
|
||||
### Gitea Actions Secrets
|
||||
|
||||
**External API keys are stored in Gitea Actions Secrets (not in .env or code).**
|
||||
|
||||
**Location:** `https://gitea.taxbaik.com/kjh2064/KArtSell.Aegis/settings/actions/secrets`
|
||||
|
||||
**Available secrets:**
|
||||
- `KRX_API_KEY` — Korea Exchange data feed (market calendar, trading sessions)
|
||||
- `OPENDART_API_KEY` — OpenDart financial disclosure API
|
||||
- `KIS_API_KEY` — Korea Investment & Securities trading API
|
||||
|
||||
**Usage in CI/CD (`.gitea/workflows/*.yml`):**
|
||||
```yaml
|
||||
env:
|
||||
KRX_API_KEY: ${{ secrets.KRX_API_KEY }}
|
||||
OPENDART_API_KEY: ${{ secrets.OPENDART_API_KEY }}
|
||||
KIS_API_KEY: ${{ secrets.KIS_API_KEY }}
|
||||
```
|
||||
|
||||
**For local development:** Ask team lead for local sandbox keys or use mock fixtures in tests.
|
||||
|
||||
### Gitea API Automation (Optional but Recommended)
|
||||
|
||||
### Environment Setup
|
||||
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
<ImplicitUsings>enable</ImplicitUsings>
|
||||
<TreatWarningsAsErrors>true</TreatWarningsAsErrors>
|
||||
<AnalysisLevel>latest-recommended</AnalysisLevel>
|
||||
<NoWarn>$(NoWarn);CA1822;CA1873;CA1305;CA1707;CA1861;xUnit2031</NoWarn>
|
||||
<NoWarn>$(NoWarn);CA1305;CA1707;CA1861;xUnit2031</NoWarn>
|
||||
<Deterministic>true</Deterministic>
|
||||
<ContinuousIntegrationBuild Condition="'$(CI)' == 'true'">true</ContinuousIntegrationBuild>
|
||||
</PropertyGroup>
|
||||
|
||||
+153
@@ -1,3 +1,4 @@
|
||||
|
||||
Microsoft Visual Studio Solution File, Format Version 12.00
|
||||
# Visual Studio Version 17
|
||||
VisualStudioVersion = 17.0.31903.59
|
||||
@@ -18,43 +19,195 @@ Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "KArtSell.Modules.ModelOpera
|
||||
EndProject
|
||||
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "KArtSell.ModelOperations.UnitTests", "tests/KArtSell.ModelOperations.UnitTests/KArtSell.ModelOperations.UnitTests.csproj", "{B0B8E43F-805E-4CA1-9D68-4E7B3F2B3502}"
|
||||
EndProject
|
||||
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "tests", "tests", "{0AB3BF05-4346-4AA6-1389-037BE0695223}"
|
||||
EndProject
|
||||
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "KArtSell.Integration.Tests", "tests\KArtSell.Integration.Tests\KArtSell.Integration.Tests.csproj", "{1223B6C2-4D20-4558-A5C0-C02B99F4A109}"
|
||||
EndProject
|
||||
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "src", "src", "{827E0CD3-B72D-47B6-A68D-7590B98EB39B}"
|
||||
EndProject
|
||||
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "KArtSell.BuildingBlocks", "src\KArtSell.BuildingBlocks\KArtSell.BuildingBlocks.csproj", "{89901704-B4A4-4C6C-9FB9-21726EF97568}"
|
||||
EndProject
|
||||
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "KArtSell.Host", "src\KArtSell.Host\KArtSell.Host.csproj", "{6C936661-4907-4C75-9167-B9017F9AA7E8}"
|
||||
EndProject
|
||||
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "KArtSell.Modules.SignalEngine", "src\KArtSell.Modules.SignalEngine\KArtSell.Modules.SignalEngine.csproj", "{B44E86C4-3ACB-46AA-85F8-5D3FC1AAA954}"
|
||||
EndProject
|
||||
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "KArtSell.Modules.ModelOperations", "src\KArtSell.Modules.ModelOperations\KArtSell.Modules.ModelOperations.csproj", "{215F2FBC-B2D9-47E0-9807-A75392D17BBA}"
|
||||
EndProject
|
||||
Global
|
||||
GlobalSection(SolutionConfigurationPlatforms) = preSolution
|
||||
Debug|Any CPU = Debug|Any CPU
|
||||
Debug|x64 = Debug|x64
|
||||
Debug|x86 = Debug|x86
|
||||
Release|Any CPU = Release|Any CPU
|
||||
Release|x64 = Release|x64
|
||||
Release|x86 = Release|x86
|
||||
EndGlobalSection
|
||||
GlobalSection(ProjectConfigurationPlatforms) = postSolution
|
||||
{5F0F6CB9-ECB2-5B9E-8FCF-2AF378C6BB82}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
|
||||
{5F0F6CB9-ECB2-5B9E-8FCF-2AF378C6BB82}.Debug|Any CPU.Build.0 = Debug|Any CPU
|
||||
{5F0F6CB9-ECB2-5B9E-8FCF-2AF378C6BB82}.Debug|x64.ActiveCfg = Debug|Any CPU
|
||||
{5F0F6CB9-ECB2-5B9E-8FCF-2AF378C6BB82}.Debug|x64.Build.0 = Debug|Any CPU
|
||||
{5F0F6CB9-ECB2-5B9E-8FCF-2AF378C6BB82}.Debug|x86.ActiveCfg = Debug|Any CPU
|
||||
{5F0F6CB9-ECB2-5B9E-8FCF-2AF378C6BB82}.Debug|x86.Build.0 = Debug|Any CPU
|
||||
{5F0F6CB9-ECB2-5B9E-8FCF-2AF378C6BB82}.Release|Any CPU.ActiveCfg = Release|Any CPU
|
||||
{5F0F6CB9-ECB2-5B9E-8FCF-2AF378C6BB82}.Release|Any CPU.Build.0 = Release|Any CPU
|
||||
{5F0F6CB9-ECB2-5B9E-8FCF-2AF378C6BB82}.Release|x64.ActiveCfg = Release|Any CPU
|
||||
{5F0F6CB9-ECB2-5B9E-8FCF-2AF378C6BB82}.Release|x64.Build.0 = Release|Any CPU
|
||||
{5F0F6CB9-ECB2-5B9E-8FCF-2AF378C6BB82}.Release|x86.ActiveCfg = Release|Any CPU
|
||||
{5F0F6CB9-ECB2-5B9E-8FCF-2AF378C6BB82}.Release|x86.Build.0 = Release|Any CPU
|
||||
{C203AEFE-E523-50DF-A0BC-66E41914E411}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
|
||||
{C203AEFE-E523-50DF-A0BC-66E41914E411}.Debug|Any CPU.Build.0 = Debug|Any CPU
|
||||
{C203AEFE-E523-50DF-A0BC-66E41914E411}.Debug|x64.ActiveCfg = Debug|Any CPU
|
||||
{C203AEFE-E523-50DF-A0BC-66E41914E411}.Debug|x64.Build.0 = Debug|Any CPU
|
||||
{C203AEFE-E523-50DF-A0BC-66E41914E411}.Debug|x86.ActiveCfg = Debug|Any CPU
|
||||
{C203AEFE-E523-50DF-A0BC-66E41914E411}.Debug|x86.Build.0 = Debug|Any CPU
|
||||
{C203AEFE-E523-50DF-A0BC-66E41914E411}.Release|Any CPU.ActiveCfg = Release|Any CPU
|
||||
{C203AEFE-E523-50DF-A0BC-66E41914E411}.Release|Any CPU.Build.0 = Release|Any CPU
|
||||
{C203AEFE-E523-50DF-A0BC-66E41914E411}.Release|x64.ActiveCfg = Release|Any CPU
|
||||
{C203AEFE-E523-50DF-A0BC-66E41914E411}.Release|x64.Build.0 = Release|Any CPU
|
||||
{C203AEFE-E523-50DF-A0BC-66E41914E411}.Release|x86.ActiveCfg = Release|Any CPU
|
||||
{C203AEFE-E523-50DF-A0BC-66E41914E411}.Release|x86.Build.0 = Release|Any CPU
|
||||
{7F4AD582-8828-5F37-A4F3-E0F8ED300BFF}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
|
||||
{7F4AD582-8828-5F37-A4F3-E0F8ED300BFF}.Debug|Any CPU.Build.0 = Debug|Any CPU
|
||||
{7F4AD582-8828-5F37-A4F3-E0F8ED300BFF}.Debug|x64.ActiveCfg = Debug|Any CPU
|
||||
{7F4AD582-8828-5F37-A4F3-E0F8ED300BFF}.Debug|x64.Build.0 = Debug|Any CPU
|
||||
{7F4AD582-8828-5F37-A4F3-E0F8ED300BFF}.Debug|x86.ActiveCfg = Debug|Any CPU
|
||||
{7F4AD582-8828-5F37-A4F3-E0F8ED300BFF}.Debug|x86.Build.0 = Debug|Any CPU
|
||||
{7F4AD582-8828-5F37-A4F3-E0F8ED300BFF}.Release|Any CPU.ActiveCfg = Release|Any CPU
|
||||
{7F4AD582-8828-5F37-A4F3-E0F8ED300BFF}.Release|Any CPU.Build.0 = Release|Any CPU
|
||||
{7F4AD582-8828-5F37-A4F3-E0F8ED300BFF}.Release|x64.ActiveCfg = Release|Any CPU
|
||||
{7F4AD582-8828-5F37-A4F3-E0F8ED300BFF}.Release|x64.Build.0 = Release|Any CPU
|
||||
{7F4AD582-8828-5F37-A4F3-E0F8ED300BFF}.Release|x86.ActiveCfg = Release|Any CPU
|
||||
{7F4AD582-8828-5F37-A4F3-E0F8ED300BFF}.Release|x86.Build.0 = Release|Any CPU
|
||||
{C1E481A2-B1C9-5647-8600-DBE8D854552F}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
|
||||
{C1E481A2-B1C9-5647-8600-DBE8D854552F}.Debug|Any CPU.Build.0 = Debug|Any CPU
|
||||
{C1E481A2-B1C9-5647-8600-DBE8D854552F}.Debug|x64.ActiveCfg = Debug|Any CPU
|
||||
{C1E481A2-B1C9-5647-8600-DBE8D854552F}.Debug|x64.Build.0 = Debug|Any CPU
|
||||
{C1E481A2-B1C9-5647-8600-DBE8D854552F}.Debug|x86.ActiveCfg = Debug|Any CPU
|
||||
{C1E481A2-B1C9-5647-8600-DBE8D854552F}.Debug|x86.Build.0 = Debug|Any CPU
|
||||
{C1E481A2-B1C9-5647-8600-DBE8D854552F}.Release|Any CPU.ActiveCfg = Release|Any CPU
|
||||
{C1E481A2-B1C9-5647-8600-DBE8D854552F}.Release|Any CPU.Build.0 = Release|Any CPU
|
||||
{C1E481A2-B1C9-5647-8600-DBE8D854552F}.Release|x64.ActiveCfg = Release|Any CPU
|
||||
{C1E481A2-B1C9-5647-8600-DBE8D854552F}.Release|x64.Build.0 = Release|Any CPU
|
||||
{C1E481A2-B1C9-5647-8600-DBE8D854552F}.Release|x86.ActiveCfg = Release|Any CPU
|
||||
{C1E481A2-B1C9-5647-8600-DBE8D854552F}.Release|x86.Build.0 = Release|Any CPU
|
||||
{FAA2A1FD-EB0C-50F6-BC9F-D571E1CF570E}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
|
||||
{FAA2A1FD-EB0C-50F6-BC9F-D571E1CF570E}.Debug|Any CPU.Build.0 = Debug|Any CPU
|
||||
{FAA2A1FD-EB0C-50F6-BC9F-D571E1CF570E}.Debug|x64.ActiveCfg = Debug|Any CPU
|
||||
{FAA2A1FD-EB0C-50F6-BC9F-D571E1CF570E}.Debug|x64.Build.0 = Debug|Any CPU
|
||||
{FAA2A1FD-EB0C-50F6-BC9F-D571E1CF570E}.Debug|x86.ActiveCfg = Debug|Any CPU
|
||||
{FAA2A1FD-EB0C-50F6-BC9F-D571E1CF570E}.Debug|x86.Build.0 = Debug|Any CPU
|
||||
{FAA2A1FD-EB0C-50F6-BC9F-D571E1CF570E}.Release|Any CPU.ActiveCfg = Release|Any CPU
|
||||
{FAA2A1FD-EB0C-50F6-BC9F-D571E1CF570E}.Release|Any CPU.Build.0 = Release|Any CPU
|
||||
{FAA2A1FD-EB0C-50F6-BC9F-D571E1CF570E}.Release|x64.ActiveCfg = Release|Any CPU
|
||||
{FAA2A1FD-EB0C-50F6-BC9F-D571E1CF570E}.Release|x64.Build.0 = Release|Any CPU
|
||||
{FAA2A1FD-EB0C-50F6-BC9F-D571E1CF570E}.Release|x86.ActiveCfg = Release|Any CPU
|
||||
{FAA2A1FD-EB0C-50F6-BC9F-D571E1CF570E}.Release|x86.Build.0 = Release|Any CPU
|
||||
{E62B968F-28A3-5055-8E5E-BFB52EC0175E}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
|
||||
{E62B968F-28A3-5055-8E5E-BFB52EC0175E}.Debug|Any CPU.Build.0 = Debug|Any CPU
|
||||
{E62B968F-28A3-5055-8E5E-BFB52EC0175E}.Debug|x64.ActiveCfg = Debug|Any CPU
|
||||
{E62B968F-28A3-5055-8E5E-BFB52EC0175E}.Debug|x64.Build.0 = Debug|Any CPU
|
||||
{E62B968F-28A3-5055-8E5E-BFB52EC0175E}.Debug|x86.ActiveCfg = Debug|Any CPU
|
||||
{E62B968F-28A3-5055-8E5E-BFB52EC0175E}.Debug|x86.Build.0 = Debug|Any CPU
|
||||
{E62B968F-28A3-5055-8E5E-BFB52EC0175E}.Release|Any CPU.ActiveCfg = Release|Any CPU
|
||||
{E62B968F-28A3-5055-8E5E-BFB52EC0175E}.Release|Any CPU.Build.0 = Release|Any CPU
|
||||
{E62B968F-28A3-5055-8E5E-BFB52EC0175E}.Release|x64.ActiveCfg = Release|Any CPU
|
||||
{E62B968F-28A3-5055-8E5E-BFB52EC0175E}.Release|x64.Build.0 = Release|Any CPU
|
||||
{E62B968F-28A3-5055-8E5E-BFB52EC0175E}.Release|x86.ActiveCfg = Release|Any CPU
|
||||
{E62B968F-28A3-5055-8E5E-BFB52EC0175E}.Release|x86.Build.0 = Release|Any CPU
|
||||
{A9A7D32E-7F4D-4B90-8C57-3D6A2E1A2401}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
|
||||
{A9A7D32E-7F4D-4B90-8C57-3D6A2E1A2401}.Debug|Any CPU.Build.0 = Debug|Any CPU
|
||||
{A9A7D32E-7F4D-4B90-8C57-3D6A2E1A2401}.Debug|x64.ActiveCfg = Debug|Any CPU
|
||||
{A9A7D32E-7F4D-4B90-8C57-3D6A2E1A2401}.Debug|x64.Build.0 = Debug|Any CPU
|
||||
{A9A7D32E-7F4D-4B90-8C57-3D6A2E1A2401}.Debug|x86.ActiveCfg = Debug|Any CPU
|
||||
{A9A7D32E-7F4D-4B90-8C57-3D6A2E1A2401}.Debug|x86.Build.0 = Debug|Any CPU
|
||||
{A9A7D32E-7F4D-4B90-8C57-3D6A2E1A2401}.Release|Any CPU.ActiveCfg = Release|Any CPU
|
||||
{A9A7D32E-7F4D-4B90-8C57-3D6A2E1A2401}.Release|Any CPU.Build.0 = Release|Any CPU
|
||||
{A9A7D32E-7F4D-4B90-8C57-3D6A2E1A2401}.Release|x64.ActiveCfg = Release|Any CPU
|
||||
{A9A7D32E-7F4D-4B90-8C57-3D6A2E1A2401}.Release|x64.Build.0 = Release|Any CPU
|
||||
{A9A7D32E-7F4D-4B90-8C57-3D6A2E1A2401}.Release|x86.ActiveCfg = Release|Any CPU
|
||||
{A9A7D32E-7F4D-4B90-8C57-3D6A2E1A2401}.Release|x86.Build.0 = Release|Any CPU
|
||||
{B0B8E43F-805E-4CA1-9D68-4E7B3F2B3502}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
|
||||
{B0B8E43F-805E-4CA1-9D68-4E7B3F2B3502}.Debug|Any CPU.Build.0 = Debug|Any CPU
|
||||
{B0B8E43F-805E-4CA1-9D68-4E7B3F2B3502}.Debug|x64.ActiveCfg = Debug|Any CPU
|
||||
{B0B8E43F-805E-4CA1-9D68-4E7B3F2B3502}.Debug|x64.Build.0 = Debug|Any CPU
|
||||
{B0B8E43F-805E-4CA1-9D68-4E7B3F2B3502}.Debug|x86.ActiveCfg = Debug|Any CPU
|
||||
{B0B8E43F-805E-4CA1-9D68-4E7B3F2B3502}.Debug|x86.Build.0 = Debug|Any CPU
|
||||
{B0B8E43F-805E-4CA1-9D68-4E7B3F2B3502}.Release|Any CPU.ActiveCfg = Release|Any CPU
|
||||
{B0B8E43F-805E-4CA1-9D68-4E7B3F2B3502}.Release|Any CPU.Build.0 = Release|Any CPU
|
||||
{B0B8E43F-805E-4CA1-9D68-4E7B3F2B3502}.Release|x64.ActiveCfg = Release|Any CPU
|
||||
{B0B8E43F-805E-4CA1-9D68-4E7B3F2B3502}.Release|x64.Build.0 = Release|Any CPU
|
||||
{B0B8E43F-805E-4CA1-9D68-4E7B3F2B3502}.Release|x86.ActiveCfg = Release|Any CPU
|
||||
{B0B8E43F-805E-4CA1-9D68-4E7B3F2B3502}.Release|x86.Build.0 = Release|Any CPU
|
||||
{1223B6C2-4D20-4558-A5C0-C02B99F4A109}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
|
||||
{1223B6C2-4D20-4558-A5C0-C02B99F4A109}.Debug|Any CPU.Build.0 = Debug|Any CPU
|
||||
{1223B6C2-4D20-4558-A5C0-C02B99F4A109}.Debug|x64.ActiveCfg = Debug|Any CPU
|
||||
{1223B6C2-4D20-4558-A5C0-C02B99F4A109}.Debug|x64.Build.0 = Debug|Any CPU
|
||||
{1223B6C2-4D20-4558-A5C0-C02B99F4A109}.Debug|x86.ActiveCfg = Debug|Any CPU
|
||||
{1223B6C2-4D20-4558-A5C0-C02B99F4A109}.Debug|x86.Build.0 = Debug|Any CPU
|
||||
{1223B6C2-4D20-4558-A5C0-C02B99F4A109}.Release|Any CPU.ActiveCfg = Release|Any CPU
|
||||
{1223B6C2-4D20-4558-A5C0-C02B99F4A109}.Release|Any CPU.Build.0 = Release|Any CPU
|
||||
{1223B6C2-4D20-4558-A5C0-C02B99F4A109}.Release|x64.ActiveCfg = Release|Any CPU
|
||||
{1223B6C2-4D20-4558-A5C0-C02B99F4A109}.Release|x64.Build.0 = Release|Any CPU
|
||||
{1223B6C2-4D20-4558-A5C0-C02B99F4A109}.Release|x86.ActiveCfg = Release|Any CPU
|
||||
{1223B6C2-4D20-4558-A5C0-C02B99F4A109}.Release|x86.Build.0 = Release|Any CPU
|
||||
{89901704-B4A4-4C6C-9FB9-21726EF97568}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
|
||||
{89901704-B4A4-4C6C-9FB9-21726EF97568}.Debug|Any CPU.Build.0 = Debug|Any CPU
|
||||
{89901704-B4A4-4C6C-9FB9-21726EF97568}.Debug|x64.ActiveCfg = Debug|Any CPU
|
||||
{89901704-B4A4-4C6C-9FB9-21726EF97568}.Debug|x64.Build.0 = Debug|Any CPU
|
||||
{89901704-B4A4-4C6C-9FB9-21726EF97568}.Debug|x86.ActiveCfg = Debug|Any CPU
|
||||
{89901704-B4A4-4C6C-9FB9-21726EF97568}.Debug|x86.Build.0 = Debug|Any CPU
|
||||
{89901704-B4A4-4C6C-9FB9-21726EF97568}.Release|Any CPU.ActiveCfg = Release|Any CPU
|
||||
{89901704-B4A4-4C6C-9FB9-21726EF97568}.Release|Any CPU.Build.0 = Release|Any CPU
|
||||
{89901704-B4A4-4C6C-9FB9-21726EF97568}.Release|x64.ActiveCfg = Release|Any CPU
|
||||
{89901704-B4A4-4C6C-9FB9-21726EF97568}.Release|x64.Build.0 = Release|Any CPU
|
||||
{89901704-B4A4-4C6C-9FB9-21726EF97568}.Release|x86.ActiveCfg = Release|Any CPU
|
||||
{89901704-B4A4-4C6C-9FB9-21726EF97568}.Release|x86.Build.0 = Release|Any CPU
|
||||
{6C936661-4907-4C75-9167-B9017F9AA7E8}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
|
||||
{6C936661-4907-4C75-9167-B9017F9AA7E8}.Debug|Any CPU.Build.0 = Debug|Any CPU
|
||||
{6C936661-4907-4C75-9167-B9017F9AA7E8}.Debug|x64.ActiveCfg = Debug|Any CPU
|
||||
{6C936661-4907-4C75-9167-B9017F9AA7E8}.Debug|x64.Build.0 = Debug|Any CPU
|
||||
{6C936661-4907-4C75-9167-B9017F9AA7E8}.Debug|x86.ActiveCfg = Debug|Any CPU
|
||||
{6C936661-4907-4C75-9167-B9017F9AA7E8}.Debug|x86.Build.0 = Debug|Any CPU
|
||||
{6C936661-4907-4C75-9167-B9017F9AA7E8}.Release|Any CPU.ActiveCfg = Release|Any CPU
|
||||
{6C936661-4907-4C75-9167-B9017F9AA7E8}.Release|Any CPU.Build.0 = Release|Any CPU
|
||||
{6C936661-4907-4C75-9167-B9017F9AA7E8}.Release|x64.ActiveCfg = Release|Any CPU
|
||||
{6C936661-4907-4C75-9167-B9017F9AA7E8}.Release|x64.Build.0 = Release|Any CPU
|
||||
{6C936661-4907-4C75-9167-B9017F9AA7E8}.Release|x86.ActiveCfg = Release|Any CPU
|
||||
{6C936661-4907-4C75-9167-B9017F9AA7E8}.Release|x86.Build.0 = Release|Any CPU
|
||||
{B44E86C4-3ACB-46AA-85F8-5D3FC1AAA954}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
|
||||
{B44E86C4-3ACB-46AA-85F8-5D3FC1AAA954}.Debug|Any CPU.Build.0 = Debug|Any CPU
|
||||
{B44E86C4-3ACB-46AA-85F8-5D3FC1AAA954}.Debug|x64.ActiveCfg = Debug|Any CPU
|
||||
{B44E86C4-3ACB-46AA-85F8-5D3FC1AAA954}.Debug|x64.Build.0 = Debug|Any CPU
|
||||
{B44E86C4-3ACB-46AA-85F8-5D3FC1AAA954}.Debug|x86.ActiveCfg = Debug|Any CPU
|
||||
{B44E86C4-3ACB-46AA-85F8-5D3FC1AAA954}.Debug|x86.Build.0 = Debug|Any CPU
|
||||
{B44E86C4-3ACB-46AA-85F8-5D3FC1AAA954}.Release|Any CPU.ActiveCfg = Release|Any CPU
|
||||
{B44E86C4-3ACB-46AA-85F8-5D3FC1AAA954}.Release|Any CPU.Build.0 = Release|Any CPU
|
||||
{B44E86C4-3ACB-46AA-85F8-5D3FC1AAA954}.Release|x64.ActiveCfg = Release|Any CPU
|
||||
{B44E86C4-3ACB-46AA-85F8-5D3FC1AAA954}.Release|x64.Build.0 = Release|Any CPU
|
||||
{B44E86C4-3ACB-46AA-85F8-5D3FC1AAA954}.Release|x86.ActiveCfg = Release|Any CPU
|
||||
{B44E86C4-3ACB-46AA-85F8-5D3FC1AAA954}.Release|x86.Build.0 = Release|Any CPU
|
||||
{215F2FBC-B2D9-47E0-9807-A75392D17BBA}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
|
||||
{215F2FBC-B2D9-47E0-9807-A75392D17BBA}.Debug|Any CPU.Build.0 = Debug|Any CPU
|
||||
{215F2FBC-B2D9-47E0-9807-A75392D17BBA}.Debug|x64.ActiveCfg = Debug|Any CPU
|
||||
{215F2FBC-B2D9-47E0-9807-A75392D17BBA}.Debug|x64.Build.0 = Debug|Any CPU
|
||||
{215F2FBC-B2D9-47E0-9807-A75392D17BBA}.Debug|x86.ActiveCfg = Debug|Any CPU
|
||||
{215F2FBC-B2D9-47E0-9807-A75392D17BBA}.Debug|x86.Build.0 = Debug|Any CPU
|
||||
{215F2FBC-B2D9-47E0-9807-A75392D17BBA}.Release|Any CPU.ActiveCfg = Release|Any CPU
|
||||
{215F2FBC-B2D9-47E0-9807-A75392D17BBA}.Release|Any CPU.Build.0 = Release|Any CPU
|
||||
{215F2FBC-B2D9-47E0-9807-A75392D17BBA}.Release|x64.ActiveCfg = Release|Any CPU
|
||||
{215F2FBC-B2D9-47E0-9807-A75392D17BBA}.Release|x64.Build.0 = Release|Any CPU
|
||||
{215F2FBC-B2D9-47E0-9807-A75392D17BBA}.Release|x86.ActiveCfg = Release|Any CPU
|
||||
{215F2FBC-B2D9-47E0-9807-A75392D17BBA}.Release|x86.Build.0 = Release|Any CPU
|
||||
EndGlobalSection
|
||||
GlobalSection(SolutionProperties) = preSolution
|
||||
HideSolutionNode = FALSE
|
||||
EndGlobalSection
|
||||
GlobalSection(NestedProjects) = preSolution
|
||||
{1223B6C2-4D20-4558-A5C0-C02B99F4A109} = {0AB3BF05-4346-4AA6-1389-037BE0695223}
|
||||
{89901704-B4A4-4C6C-9FB9-21726EF97568} = {827E0CD3-B72D-47B6-A68D-7590B98EB39B}
|
||||
{6C936661-4907-4C75-9167-B9017F9AA7E8} = {827E0CD3-B72D-47B6-A68D-7590B98EB39B}
|
||||
{B44E86C4-3ACB-46AA-85F8-5D3FC1AAA954} = {827E0CD3-B72D-47B6-A68D-7590B98EB39B}
|
||||
{215F2FBC-B2D9-47E0-9807-A75392D17BBA} = {827E0CD3-B72D-47B6-A68D-7590B98EB39B}
|
||||
EndGlobalSection
|
||||
EndGlobal
|
||||
|
||||
+16
-13
@@ -8,9 +8,12 @@
|
||||
|
||||
| Status | Count | Total Impact |
|
||||
|--------|-------|--------------|
|
||||
| Backlog | 8 | 20 pts |
|
||||
| Backlog | 0 | 0 pts |
|
||||
| In Progress | 0 | 0 pts |
|
||||
| Completed | 0 | 0 pts |
|
||||
| Completed | 1 | 1 pt |
|
||||
| No Action | 1 | 1 pt |
|
||||
| Deferred | 4 | 4 pts |
|
||||
| Accepted | 1 | 2 pts |
|
||||
|
||||
---
|
||||
|
||||
@@ -20,19 +23,19 @@
|
||||
|
||||
| ID | Category | Impact | Effort | Status | Notes | Owner | ADR |
|
||||
|----|----------|--------|--------|--------|-------|-------|-----|
|
||||
| DEBT-001 | CA1822 (static hints) | Low (1) | Low (1) | Backlog | Analyzer suggestions for instance methods that could be static. Not performance-critical; batch during refactors. | Team | - |
|
||||
| DEBT-002 | CA1873 (array logging) | Low (1) | Low (1) | Backlog | Conditional array evaluation in logging. Low runtime impact; defer until performance profiling. | Team | - |
|
||||
| DEBT-003 | CA1305 (culture) | Low (1) | Low (1) | Backlog | Locale-specific formatting. Accept as-is for Serilog; breaking change if fixed. | Team | - |
|
||||
| DEBT-004 | CA1707 (test naming) | Low (1) | Low (1) | Backlog | xUnit underscores in test names. Convention; no fix needed. | Team | - |
|
||||
| DEBT-005 | CA1861 (array overhead) | Low (1) | Low (1) | Backlog | Static readonly array allocations. Negligible perf; accept trade-off for readability. | Team | - |
|
||||
| DEBT-006 | xUnit2031 (filter) | Low (1) | Low (1) | Backlog | Use overload instead of .Where() for Assert.Single. Analyzer nit; defer. | Team | - |
|
||||
| DEBT-001 | CA1822 (static hints) | Low (1) | Low (1) | Completed | Applied `static` to GetNextDueAt, Evaluate, Plan methods; removed DI registrations. | @claude | PR 4b |
|
||||
| DEBT-002 | CA1873 (array logging) | Low (1) | Low (1) | No Action | Already compliant: all logging uses LoggerMessage delegates. Verified PR 4b build with CA1873 enabled: 0 warnings. | @claude | Verified |
|
||||
| DEBT-003 | CA1305 (culture) | Low (1) | Low (1) | Deferred | Locale-specific formatting. Accept as-is for Serilog; breaking change if fixed. Revisit if conditions change. | @claude | PR 4d |
|
||||
| DEBT-004 | CA1707 (test naming) | Low (1) | Low (1) | Deferred | xUnit underscores in test names. Convention; no fix needed. Revisit if conditions change. | @claude | PR 4d |
|
||||
| DEBT-005 | CA1861 (array overhead) | Low (1) | Low (1) | Deferred | Static readonly array allocations. Negligible perf; accept trade-off for readability. Revisit if conditions change. | @claude | PR 4d |
|
||||
| DEBT-006 | xUnit2031 (filter) | Low (1) | Low (1) | Deferred | Use overload instead of .Where() for Assert.Single. Analyzer nit; defer. Revisit if conditions change. | @claude | PR 4d |
|
||||
|
||||
### Deferred Refactoring
|
||||
|
||||
| ID | Category | Impact | Effort | Status | Notes | Owner | ADR |
|
||||
|----|----------|--------|--------|--------|-------|-------|-----|
|
||||
| DEBT-007 | Newtonsoft.Json override | Medium (2) | Medium (2) | Completed | Fixed in 88ea5ed: CA1848/CA1859 actual implementation. LoggerMessage + HashSet/Dictionary. | @claude | - |
|
||||
| DEBT-008 | Namespace consistency | Medium (2) | Low (1) | Backlog | All projects use RootNamespace=KArtSell.Aegis; AssemblyName retained per-project for DLL clarity. Consider if alignment needed. | - | - |
|
||||
| DEBT-008 | Namespace consistency | Medium (2) | Low (1) | Accepted | All projects use RootNamespace=KArtSell.Aegis; AssemblyName retained per-project for DLL clarity. Trade-off accepted: DLL clarity > namespace alignment. No action. | @claude | PR 4d |
|
||||
|
||||
---
|
||||
|
||||
@@ -47,12 +50,12 @@ Low Impact QUICK WINS MONITOR
|
||||
(DEBT-001/002) (DEBT-003/004/005/006/008)
|
||||
```
|
||||
|
||||
### Quick Wins — Q3 2026 (To Resolve)
|
||||
### Quick Wins — Q3 2026 (Completed)
|
||||
|
||||
**Rationale (per AGENTS.md v16.0 "Paydown Target: 20% quarterly"):**
|
||||
- DEBT-001 (CA1822): static method hints — True performance benefit. Easy to fix with `static` modifier. **Target: PR 4c**
|
||||
- DEBT-002 (CA1873): array logging — Avoid unnecessary array allocation in conditional log. Easy fix with guard check. **Target: PR 4d**
|
||||
- Result: +2 pts resolved (4pts total for Q3 target) ✅
|
||||
- ✅ DEBT-001 (CA1822): static method hints — Completed in PR 4b. Applied `static` to ScheduleOccurrencePlanner.GetNextDueAt, PromotionGateEvaluator.Evaluate, EvaluationWindowPlanner.Plan; removed unnecessary DI registrations (+1 pt).
|
||||
- ✅ DEBT-002 (CA1873): array logging — Already compliant: all logging uses LoggerMessage delegates. Verified in PR 4b build with CA1873 enabled: 0 warnings. No action needed (+0 pts, marked "No Action").
|
||||
- Result: +1 pt resolved (25% of 4pt target). Target rate achievable by completing additional small-effort items from remaining backlog.
|
||||
|
||||
### Batch During Feature Work
|
||||
- ~~DEBT-001~~, ~~DEBT-002~~ — Moving to Quick Wins (PR 4 priority)
|
||||
|
||||
@@ -56,7 +56,7 @@ create table if not exists signal_engine.policy_contract_definition (
|
||||
insert into signal_engine.policy_contract_definition
|
||||
(contract_version, content_hash, policy_json, status)
|
||||
values
|
||||
('sell-policy.v1', 'a269a0331b83c0f6ec108e7587de1d20c798036ff8d0c03d726cd854e73d8480', $policy$
|
||||
('sell-policy.v1', 'a269a0331b83c0f6ec108e7587de1d20c798036ff8d0c03d726cd854e73d8480', $$
|
||||
{
|
||||
"changeControl": "MODEL_CHANGE_AND_GOLDEN_OOS_REQUIRED",
|
||||
"contractVersion": "sell-policy.v1",
|
||||
@@ -140,7 +140,7 @@ values
|
||||
"policyTraceSchemaVersion": 2,
|
||||
"status": "RESEARCH_CANDIDATE_NOT_PRODUCTION"
|
||||
}
|
||||
$policy$::jsonb, 'PROPOSED')
|
||||
$$::jsonb, 'PROPOSED')
|
||||
on conflict (contract_version) do nothing;
|
||||
|
||||
drop trigger if exists policy_contract_definition_immutable on signal_engine.policy_contract_definition;
|
||||
|
||||
@@ -25,6 +25,7 @@
|
||||
},
|
||||
"devDependencies": {
|
||||
"@playwright/test": "^1.0.0",
|
||||
"@types/node": "^26.1.2",
|
||||
"@vitejs/plugin-vue": "^6.0.0",
|
||||
"@vue/test-utils": "^2.0.0",
|
||||
"jsdom": "^26.0.0",
|
||||
|
||||
Generated
+2247
File diff suppressed because it is too large
Load Diff
@@ -0,0 +1,83 @@
|
||||
import { RouterLink, RouterView } from 'vue-router';
|
||||
import { AppShellLayout } from './shared/ui/layouts';
|
||||
const __VLS_ctx = {
|
||||
...{},
|
||||
...{},
|
||||
};
|
||||
let __VLS_components;
|
||||
let __VLS_intrinsics;
|
||||
let __VLS_directives;
|
||||
/** @type {__VLS_StyleScopedClasses['app-nav']} */ ;
|
||||
/** @type {__VLS_StyleScopedClasses['app-nav']} */ ;
|
||||
let __VLS_0;
|
||||
/** @ts-ignore @type { | typeof __VLS_components.AppShellLayout | typeof __VLS_components.AppShellLayout} */
|
||||
AppShellLayout;
|
||||
// @ts-ignore
|
||||
const __VLS_1 = __VLS_asFunctionalComponent1(__VLS_0, new __VLS_0({}));
|
||||
const __VLS_2 = __VLS_1({}, ...__VLS_functionalComponentArgsRest(__VLS_1));
|
||||
var __VLS_5;
|
||||
const { default: __VLS_6 } = __VLS_3.slots;
|
||||
{
|
||||
const { navigation: __VLS_7 } = __VLS_3.slots;
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.nav, __VLS_intrinsics.nav)({
|
||||
...{ class: "app-nav" },
|
||||
});
|
||||
/** @type {__VLS_StyleScopedClasses['app-nav']} */ ;
|
||||
let __VLS_8;
|
||||
/** @ts-ignore @type { | typeof __VLS_components.RouterLink | typeof __VLS_components.RouterLink} */
|
||||
RouterLink;
|
||||
// @ts-ignore
|
||||
const __VLS_9 = __VLS_asFunctionalComponent1(__VLS_8, new __VLS_8({
|
||||
to: "/research/sell-decision",
|
||||
}));
|
||||
const __VLS_10 = __VLS_9({
|
||||
to: "/research/sell-decision",
|
||||
}, ...__VLS_functionalComponentArgsRest(__VLS_9));
|
||||
const { default: __VLS_13 } = __VLS_11.slots;
|
||||
var __VLS_11;
|
||||
let __VLS_14;
|
||||
/** @ts-ignore @type { | typeof __VLS_components.RouterLink | typeof __VLS_components.RouterLink} */
|
||||
RouterLink;
|
||||
// @ts-ignore
|
||||
const __VLS_15 = __VLS_asFunctionalComponent1(__VLS_14, new __VLS_14({
|
||||
to: "/ops/data-quality",
|
||||
}));
|
||||
const __VLS_16 = __VLS_15({
|
||||
to: "/ops/data-quality",
|
||||
}, ...__VLS_functionalComponentArgsRest(__VLS_15));
|
||||
const { default: __VLS_19 } = __VLS_17.slots;
|
||||
var __VLS_17;
|
||||
let __VLS_20;
|
||||
/** @ts-ignore @type { | typeof __VLS_components.RouterLink | typeof __VLS_components.RouterLink} */
|
||||
RouterLink;
|
||||
// @ts-ignore
|
||||
const __VLS_21 = __VLS_asFunctionalComponent1(__VLS_20, new __VLS_20({
|
||||
to: "/ops/model-operations",
|
||||
}));
|
||||
const __VLS_22 = __VLS_21({
|
||||
to: "/ops/model-operations",
|
||||
}, ...__VLS_functionalComponentArgsRest(__VLS_21));
|
||||
const { default: __VLS_25 } = __VLS_23.slots;
|
||||
var __VLS_23;
|
||||
let __VLS_26;
|
||||
/** @ts-ignore @type { | typeof __VLS_components.RouterLink | typeof __VLS_components.RouterLink} */
|
||||
RouterLink;
|
||||
// @ts-ignore
|
||||
const __VLS_27 = __VLS_asFunctionalComponent1(__VLS_26, new __VLS_26({
|
||||
to: "/internal/ui-standard",
|
||||
}));
|
||||
const __VLS_28 = __VLS_27({
|
||||
to: "/internal/ui-standard",
|
||||
}, ...__VLS_functionalComponentArgsRest(__VLS_27));
|
||||
const { default: __VLS_31 } = __VLS_29.slots;
|
||||
var __VLS_29;
|
||||
}
|
||||
let __VLS_32;
|
||||
/** @ts-ignore @type { | typeof __VLS_components.RouterView} */
|
||||
RouterView;
|
||||
// @ts-ignore
|
||||
const __VLS_33 = __VLS_asFunctionalComponent1(__VLS_32, new __VLS_32({}));
|
||||
const __VLS_34 = __VLS_33({}, ...__VLS_functionalComponentArgsRest(__VLS_33));
|
||||
var __VLS_3;
|
||||
const __VLS_export = (await import('vue')).defineComponent({});
|
||||
export default {};
|
||||
@@ -0,0 +1,16 @@
|
||||
import { QueryClient } from '@tanstack/vue-query';
|
||||
export const queryClient = new QueryClient({
|
||||
defaultOptions: {
|
||||
queries: {
|
||||
staleTime: 30_000,
|
||||
retry: (failureCount, error) => {
|
||||
const status = typeof error === 'object' && error !== null && 'status' in error
|
||||
? Number(error.status)
|
||||
: 0;
|
||||
return ![400, 401, 403, 404, 409, 422].includes(status) && failureCount < 2;
|
||||
},
|
||||
refetchOnWindowFocus: false
|
||||
},
|
||||
mutations: { retry: false }
|
||||
}
|
||||
});
|
||||
@@ -0,0 +1,15 @@
|
||||
import { createRouter, createWebHistory } from 'vue-router';
|
||||
import SellDecisionPage from '../features/sell-decision/pages/SellDecisionPage.vue';
|
||||
import DataQualityPage from '../features/data-quality/pages/DataQualityPage.vue';
|
||||
import ModelOperationsPage from '../features/model-operations/pages/ModelOperationsPage.vue';
|
||||
import UiStandardPage from '../features/ui-standard/pages/UiStandardPage.vue';
|
||||
export const router = createRouter({
|
||||
history: createWebHistory(),
|
||||
routes: [
|
||||
{ path: '/', redirect: '/research/sell-decision' },
|
||||
{ path: '/research/sell-decision', component: SellDecisionPage, meta: { screenId: 'SCR-002', templateId: 'T02' } },
|
||||
{ path: '/ops/data-quality', component: DataQualityPage, meta: { screenId: 'SCR-013', templateId: 'T08' } },
|
||||
{ path: '/ops/model-operations', component: ModelOperationsPage, meta: { screenId: 'SCR-015', templateId: 'T10' } },
|
||||
{ path: '/internal/ui-standard', component: UiStandardPage, meta: { screenId: 'SCR-DEV-001', templateId: 'T01', internalOnly: true } }
|
||||
]
|
||||
});
|
||||
@@ -0,0 +1,41 @@
|
||||
import { computed } from 'vue';
|
||||
import DataGridShell from '../../../shared/ui/DataGridShell.vue';
|
||||
// Template fixture only. Production data must come from DAT-03 and pass Zod validation.
|
||||
const rows = [];
|
||||
const columns = computed(() => [
|
||||
{ field: 'source', header: 'Source' },
|
||||
{ field: 'session', header: 'Session' },
|
||||
{ field: 'status', header: 'DQ' },
|
||||
{ field: 'rowCount', header: 'Rows' },
|
||||
{ field: 'failedRows', header: 'Failed' },
|
||||
{ field: 'sourceWatermark', header: 'Watermark' },
|
||||
{ field: 'datasetId', header: 'Dataset' },
|
||||
{ field: 'completedAt', header: 'Completed' }
|
||||
]);
|
||||
const __VLS_ctx = {
|
||||
...{},
|
||||
...{},
|
||||
};
|
||||
let __VLS_components;
|
||||
let __VLS_intrinsics;
|
||||
let __VLS_directives;
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.main, __VLS_intrinsics.main)({});
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.header, __VLS_intrinsics.header)({});
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.h1, __VLS_intrinsics.h1)({});
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.p, __VLS_intrinsics.p)({});
|
||||
const __VLS_0 = DataGridShell;
|
||||
// @ts-ignore
|
||||
const __VLS_1 = __VLS_asFunctionalComponent1(__VLS_0, new __VLS_0({
|
||||
rows: (__VLS_ctx.rows),
|
||||
columns: (__VLS_ctx.columns),
|
||||
emptyMessage: "DAT-03 계약이 구현되면 서버 검증 결과가 표시됩니다.",
|
||||
}));
|
||||
const __VLS_2 = __VLS_1({
|
||||
rows: (__VLS_ctx.rows),
|
||||
columns: (__VLS_ctx.columns),
|
||||
emptyMessage: "DAT-03 계약이 구현되면 서버 검증 결과가 표시됩니다.",
|
||||
}, ...__VLS_functionalComponentArgsRest(__VLS_1));
|
||||
// @ts-ignore
|
||||
[rows, columns,];
|
||||
const __VLS_export = (await import('vue')).defineComponent({});
|
||||
export default {};
|
||||
@@ -0,0 +1,23 @@
|
||||
import { z } from 'zod';
|
||||
export const dataQualityStatusSchema = z.enum(['PASS', 'WARN', 'QUARANTINED']);
|
||||
export const dataQualityRunSchema = z.object({
|
||||
runId: z.string().uuid(),
|
||||
source: z.string().min(1),
|
||||
session: z.string().min(1),
|
||||
status: dataQualityStatusSchema,
|
||||
rowCount: z.number().int().nonnegative(),
|
||||
failedRows: z.number().int().nonnegative(),
|
||||
sourceWatermark: z.string().min(1),
|
||||
datasetId: z.string().min(1),
|
||||
contentHash: z.string().min(1),
|
||||
completedAt: z.string().datetime({ offset: true })
|
||||
}).superRefine((value, ctx) => {
|
||||
if (value.failedRows > value.rowCount) {
|
||||
ctx.addIssue({
|
||||
code: z.ZodIssueCode.custom,
|
||||
message: '실패 행 수는 전체 행 수를 초과할 수 없습니다.',
|
||||
path: ['failedRows']
|
||||
});
|
||||
}
|
||||
});
|
||||
export const dataQualityRunsSchema = z.array(dataQualityRunSchema);
|
||||
@@ -0,0 +1,22 @@
|
||||
import { describe, expect, it } from 'vitest';
|
||||
import { dataQualityRunSchema } from '../schema';
|
||||
const valid = {
|
||||
runId: '00000000-0000-0000-0000-000000000001',
|
||||
source: 'KRX',
|
||||
session: '2026-08-01',
|
||||
status: 'PASS',
|
||||
rowCount: 100,
|
||||
failedRows: 0,
|
||||
sourceWatermark: 'KRX:2026-08-01',
|
||||
datasetId: 'dataset-1',
|
||||
contentHash: 'hash-1',
|
||||
completedAt: '2026-08-01T09:00:00Z'
|
||||
};
|
||||
describe('data quality contract', () => {
|
||||
it('accepts a valid run', () => {
|
||||
expect(dataQualityRunSchema.safeParse(valid).success).toBe(true);
|
||||
});
|
||||
it('rejects failed rows greater than total rows', () => {
|
||||
expect(dataQualityRunSchema.safeParse({ ...valid, failedRows: 101 }).success).toBe(false);
|
||||
});
|
||||
});
|
||||
@@ -0,0 +1,6 @@
|
||||
import { api } from '../../shared/api/client';
|
||||
import { modelOperationsPlanSchema } from './schema';
|
||||
export async function getModelOperationsPlan() {
|
||||
const response = await api.get('/internal/v1/model-operations/plan');
|
||||
return modelOperationsPlanSchema.parse(response.data);
|
||||
}
|
||||
@@ -0,0 +1,35 @@
|
||||
const __VLS_props = defineProps();
|
||||
const __VLS_ctx = {
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
};
|
||||
let __VLS_components;
|
||||
let __VLS_intrinsics;
|
||||
let __VLS_directives;
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.section, __VLS_intrinsics.section)({
|
||||
'aria-labelledby': "automation-boundary-title",
|
||||
});
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.h2, __VLS_intrinsics.h2)({
|
||||
id: "automation-boundary-title",
|
||||
});
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.dl, __VLS_intrinsics.dl)({});
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.div, __VLS_intrinsics.div)({});
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.dt, __VLS_intrinsics.dt)({});
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.dd, __VLS_intrinsics.dd)({});
|
||||
(__VLS_ctx.algorithmStatus);
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.div, __VLS_intrinsics.div)({});
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.dt, __VLS_intrinsics.dt)({});
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.dd, __VLS_intrinsics.dd)({});
|
||||
(__VLS_ctx.orderCapability);
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.div, __VLS_intrinsics.div)({});
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.dt, __VLS_intrinsics.dt)({});
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.dd, __VLS_intrinsics.dd)({});
|
||||
(__VLS_ctx.modelMutationBoundary);
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.p, __VLS_intrinsics.p)({});
|
||||
// @ts-ignore
|
||||
[algorithmStatus, orderCapability, modelMutationBoundary,];
|
||||
const __VLS_export = (await import('vue')).defineComponent({
|
||||
__typeProps: {},
|
||||
});
|
||||
export default {};
|
||||
@@ -0,0 +1,61 @@
|
||||
const __VLS_props = defineProps();
|
||||
const __VLS_ctx = {
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
};
|
||||
let __VLS_components;
|
||||
let __VLS_intrinsics;
|
||||
let __VLS_directives;
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.section, __VLS_intrinsics.section)({
|
||||
'aria-labelledby': "operation-plan-title",
|
||||
});
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.h2, __VLS_intrinsics.h2)({
|
||||
id: "operation-plan-title",
|
||||
});
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.div, __VLS_intrinsics.div)({
|
||||
...{ class: "table-wrap" },
|
||||
});
|
||||
/** @type {__VLS_StyleScopedClasses['table-wrap']} */ ;
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.table, __VLS_intrinsics.table)({});
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.thead, __VLS_intrinsics.thead)({});
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.tr, __VLS_intrinsics.tr)({});
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.th, __VLS_intrinsics.th)({});
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.th, __VLS_intrinsics.th)({});
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.th, __VLS_intrinsics.th)({});
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.th, __VLS_intrinsics.th)({});
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.th, __VLS_intrinsics.th)({});
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.th, __VLS_intrinsics.th)({});
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.th, __VLS_intrinsics.th)({});
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.th, __VLS_intrinsics.th)({});
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.tbody, __VLS_intrinsics.tbody)({});
|
||||
for (const [operation] of __VLS_vFor((__VLS_ctx.operations))) {
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.tr, __VLS_intrinsics.tr)({
|
||||
key: (operation.operationCode),
|
||||
});
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.td, __VLS_intrinsics.td)({});
|
||||
(operation.operationCode);
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.td, __VLS_intrinsics.td)({});
|
||||
(operation.name);
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.td, __VLS_intrinsics.td)({});
|
||||
(operation.cadence);
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.td, __VLS_intrinsics.td)({});
|
||||
(operation.automationMode);
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.td, __VLS_intrinsics.td)({});
|
||||
(operation.queue);
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.td, __VLS_intrinsics.td)({});
|
||||
(operation.gate);
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.td, __VLS_intrinsics.td)({});
|
||||
(operation.primaryOwner);
|
||||
(operation.secondaryOwner);
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.td, __VLS_intrinsics.td)({});
|
||||
(operation.output);
|
||||
// @ts-ignore
|
||||
[operations,];
|
||||
}
|
||||
// @ts-ignore
|
||||
[];
|
||||
const __VLS_export = (await import('vue')).defineComponent({
|
||||
__typeProps: {},
|
||||
});
|
||||
export default {};
|
||||
@@ -0,0 +1,58 @@
|
||||
import QueryStateBoundary from '../../../shared/ui/QueryStateBoundary.vue';
|
||||
import AutomationBoundaryPanel from '../components/AutomationBoundaryPanel.vue';
|
||||
import ModelOperationTable from '../components/ModelOperationTable.vue';
|
||||
import { useModelOperationsPlanQuery } from '../queries';
|
||||
const planQuery = useModelOperationsPlanQuery();
|
||||
const __VLS_ctx = {
|
||||
...{},
|
||||
...{},
|
||||
};
|
||||
let __VLS_components;
|
||||
let __VLS_intrinsics;
|
||||
let __VLS_directives;
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.article, __VLS_intrinsics.article)({});
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.header, __VLS_intrinsics.header)({});
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.h1, __VLS_intrinsics.h1)({});
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.p, __VLS_intrinsics.p)({});
|
||||
const __VLS_0 = QueryStateBoundary || QueryStateBoundary;
|
||||
// @ts-ignore
|
||||
const __VLS_1 = __VLS_asFunctionalComponent1(__VLS_0, new __VLS_0({
|
||||
loading: (__VLS_ctx.planQuery.isLoading.value),
|
||||
error: __VLS_ctx.planQuery.error.value,
|
||||
empty: (!__VLS_ctx.planQuery.data.value),
|
||||
}));
|
||||
const __VLS_2 = __VLS_1({
|
||||
loading: (__VLS_ctx.planQuery.isLoading.value),
|
||||
error: __VLS_ctx.planQuery.error.value,
|
||||
empty: (!__VLS_ctx.planQuery.data.value),
|
||||
}, ...__VLS_functionalComponentArgsRest(__VLS_1));
|
||||
const { default: __VLS_5 } = __VLS_3.slots;
|
||||
if (__VLS_ctx.planQuery.data.value) {
|
||||
const __VLS_6 = AutomationBoundaryPanel;
|
||||
// @ts-ignore
|
||||
const __VLS_7 = __VLS_asFunctionalComponent1(__VLS_6, new __VLS_6({
|
||||
algorithmStatus: (__VLS_ctx.planQuery.data.value.algorithmStatus),
|
||||
orderCapability: (__VLS_ctx.planQuery.data.value.orderCapability),
|
||||
modelMutationBoundary: (__VLS_ctx.planQuery.data.value.modelMutationBoundary),
|
||||
}));
|
||||
const __VLS_8 = __VLS_7({
|
||||
algorithmStatus: (__VLS_ctx.planQuery.data.value.algorithmStatus),
|
||||
orderCapability: (__VLS_ctx.planQuery.data.value.orderCapability),
|
||||
modelMutationBoundary: (__VLS_ctx.planQuery.data.value.modelMutationBoundary),
|
||||
}, ...__VLS_functionalComponentArgsRest(__VLS_7));
|
||||
const __VLS_11 = ModelOperationTable;
|
||||
// @ts-ignore
|
||||
const __VLS_12 = __VLS_asFunctionalComponent1(__VLS_11, new __VLS_11({
|
||||
operations: (__VLS_ctx.planQuery.data.value.operations),
|
||||
}));
|
||||
const __VLS_13 = __VLS_12({
|
||||
operations: (__VLS_ctx.planQuery.data.value.operations),
|
||||
}, ...__VLS_functionalComponentArgsRest(__VLS_12));
|
||||
}
|
||||
// @ts-ignore
|
||||
[planQuery, planQuery, planQuery, planQuery, planQuery, planQuery, planQuery, planQuery,];
|
||||
var __VLS_3;
|
||||
// @ts-ignore
|
||||
[];
|
||||
const __VLS_export = (await import('vue')).defineComponent({});
|
||||
export default {};
|
||||
@@ -0,0 +1,14 @@
|
||||
import { useQuery } from '@tanstack/vue-query';
|
||||
import { getModelOperationsPlan } from './api';
|
||||
export const modelOperationsKeys = {
|
||||
all: ['model-operations'],
|
||||
plan: () => [...modelOperationsKeys.all, 'plan']
|
||||
};
|
||||
export function useModelOperationsPlanQuery() {
|
||||
return useQuery({
|
||||
queryKey: modelOperationsKeys.plan(),
|
||||
queryFn: getModelOperationsPlan,
|
||||
staleTime: 5 * 60 * 1000,
|
||||
retry: 1
|
||||
});
|
||||
}
|
||||
@@ -0,0 +1,19 @@
|
||||
import { z } from 'zod';
|
||||
export const operationItemSchema = z.object({
|
||||
operationCode: z.string().min(1),
|
||||
name: z.string().min(1),
|
||||
cadence: z.enum(['DAILY', 'WEEKLY', 'MONTHLY', 'QUARTERLY', 'EVENT_DRIVEN']),
|
||||
automationMode: z.enum(['EVALUATION_ONLY', 'PROPOSAL_ONLY', 'DRILL_ONLY']),
|
||||
queue: z.string().min(1),
|
||||
primaryOwner: z.string().min(1),
|
||||
secondaryOwner: z.string().min(1),
|
||||
requiredEvidence: z.string().min(1),
|
||||
output: z.string().min(1),
|
||||
gate: z.string().min(1)
|
||||
});
|
||||
export const modelOperationsPlanSchema = z.object({
|
||||
algorithmStatus: z.literal('RESEARCH_CANDIDATE_NOT_PRODUCTION'),
|
||||
orderCapability: z.literal('AUTOMATIC_ORDER_AND_KIS_SUBMISSION_OFF'),
|
||||
modelMutationBoundary: z.literal('EVALUATION_AND_PROPOSAL_ONLY_HUMAN_APPROVAL_REQUIRED'),
|
||||
operations: z.array(operationItemSchema)
|
||||
});
|
||||
@@ -0,0 +1,24 @@
|
||||
import { describe, expect, it } from 'vitest';
|
||||
import { modelOperationsPlanSchema } from '../schema';
|
||||
describe('model operations plan schema', () => {
|
||||
it('rejects an automatic promotion mode', () => {
|
||||
const result = modelOperationsPlanSchema.safeParse({
|
||||
algorithmStatus: 'RESEARCH_CANDIDATE_NOT_PRODUCTION',
|
||||
orderCapability: 'AUTOMATIC_ORDER_AND_KIS_SUBMISSION_OFF',
|
||||
modelMutationBoundary: 'EVALUATION_AND_PROPOSAL_ONLY_HUMAN_APPROVAL_REQUIRED',
|
||||
operations: [{
|
||||
operationCode: 'J22',
|
||||
name: 'PromotionEvidenceReviewBuild',
|
||||
cadence: 'MONTHLY',
|
||||
automationMode: 'AUTO_PROMOTE',
|
||||
queue: 'q-control',
|
||||
primaryOwner: 'Risk',
|
||||
secondaryOwner: 'Compliance',
|
||||
requiredEvidence: 'all evidence',
|
||||
output: 'review packet',
|
||||
gate: 'G4'
|
||||
}]
|
||||
});
|
||||
expect(result.success).toBe(false);
|
||||
});
|
||||
});
|
||||
@@ -0,0 +1,7 @@
|
||||
import { api } from '../../shared/api/client';
|
||||
import { researchSellPolicyRequestSchema, researchSellPolicyResponseSchema } from './schema';
|
||||
export async function evaluateResearchSellPolicy(command) {
|
||||
const request = researchSellPolicyRequestSchema.parse(command.request);
|
||||
const { data } = await api.post('/internal/v1/research/sell-policy/evaluate', request, { headers: { 'Idempotency-Key': command.idempotencyKey } });
|
||||
return researchSellPolicyResponseSchema.parse(data);
|
||||
}
|
||||
@@ -0,0 +1,48 @@
|
||||
import { computed } from 'vue';
|
||||
const props = defineProps();
|
||||
const dispositionLabel = { 0: 'NOT_APPLICABLE', 1: 'BLOCKED', 2: 'APPLIED' };
|
||||
const ordered = computed(() => [...props.entries].sort((a, b) => b.priority - a.priority));
|
||||
const __VLS_ctx = {
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
};
|
||||
let __VLS_components;
|
||||
let __VLS_intrinsics;
|
||||
let __VLS_directives;
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.section, __VLS_intrinsics.section)({
|
||||
'aria-labelledby': "policy-trace-title",
|
||||
});
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.h2, __VLS_intrinsics.h2)({
|
||||
id: "policy-trace-title",
|
||||
});
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.p, __VLS_intrinsics.p)({});
|
||||
(props.schemaVersion);
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.ol, __VLS_intrinsics.ol)({});
|
||||
for (const [entry] of __VLS_vFor((__VLS_ctx.ordered))) {
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.li, __VLS_intrinsics.li)({
|
||||
key: (`${entry.priority}-${entry.policyId}`),
|
||||
});
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.strong, __VLS_intrinsics.strong)({});
|
||||
(entry.policyId);
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.span, __VLS_intrinsics.span)({});
|
||||
(__VLS_ctx.dispositionLabel[entry.disposition]);
|
||||
(entry.reasonCode);
|
||||
if (entry.requestedSellRatioOfLot > 0) {
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.span, __VLS_intrinsics.span)({});
|
||||
(entry.requestedSellRatioOfLot);
|
||||
(entry.appliedSellRatioOfLot);
|
||||
}
|
||||
if (entry.strategicCoreClampApplied) {
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.span, __VLS_intrinsics.span)({});
|
||||
}
|
||||
// @ts-ignore
|
||||
[ordered, dispositionLabel,];
|
||||
}
|
||||
// @ts-ignore
|
||||
[];
|
||||
const __VLS_export = (await import('vue')).defineComponent({
|
||||
__typeProps: {},
|
||||
});
|
||||
export default {};
|
||||
@@ -0,0 +1,162 @@
|
||||
import { computed, ref } from 'vue';
|
||||
import QueryStateBoundary from '../../../shared/ui/QueryStateBoundary.vue';
|
||||
import PolicyTracePanel from '../components/PolicyTracePanel.vue';
|
||||
import { useEvaluateResearchSellPolicy } from '../queries';
|
||||
const mutation = useEvaluateResearchSellPolicy();
|
||||
const hardImpairmentApproved = ref(false);
|
||||
const capitalFloorBreached = ref(false);
|
||||
const gapBelowFloorAtr = ref(1.6);
|
||||
const consecutiveCloseBreaches = ref(0);
|
||||
const lastCommand = ref(null);
|
||||
const isBusy = computed(() => mutation.isPending.value);
|
||||
function createCommand() {
|
||||
const asOf = new Date().toISOString();
|
||||
return {
|
||||
idempotencyKey: crypto.randomUUID(),
|
||||
request: {
|
||||
positionLotId: '00000000-0000-0000-0000-000000000001',
|
||||
cycleId: '00000000-0000-0000-0000-000000000002',
|
||||
evidenceId: 'sample-evidence',
|
||||
datasetId: 'sample-dataset',
|
||||
modelVersion: 'research-v12.2',
|
||||
configVersion: 'proposal-v12.2',
|
||||
codeSha: 'sample-code-sha',
|
||||
asOf,
|
||||
publishedAtCutoff: asOf,
|
||||
currentSecurityPortfolioWeight: 0.6,
|
||||
currentLotPortfolioWeight: 0.2,
|
||||
strategicCoreFloorWeight: 0.3,
|
||||
hardImpairmentApproved: hardImpairmentApproved.value,
|
||||
capitalFloorBreached: capitalFloorBreached.value,
|
||||
survivalSellRatioOfLot: 0.5,
|
||||
gapBelowFloorAtr: gapBelowFloorAtr.value,
|
||||
consecutiveCloseBreaches: consecutiveCloseBreaches.value,
|
||||
cooldownSatisfied: true,
|
||||
concentrationSellRatioOfLot: 0,
|
||||
opportunityEdgeLowerBound: 0,
|
||||
opportunitySellRatioOfLot: 0
|
||||
}
|
||||
};
|
||||
}
|
||||
function run() {
|
||||
const command = createCommand();
|
||||
lastCommand.value = command;
|
||||
mutation.mutate(command);
|
||||
}
|
||||
function retry() {
|
||||
if (lastCommand.value)
|
||||
mutation.mutate(lastCommand.value);
|
||||
}
|
||||
const __VLS_ctx = {
|
||||
...{},
|
||||
...{},
|
||||
};
|
||||
let __VLS_components;
|
||||
let __VLS_intrinsics;
|
||||
let __VLS_directives;
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.main, __VLS_intrinsics.main)({});
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.header, __VLS_intrinsics.header)({});
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.h1, __VLS_intrinsics.h1)({});
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.p, __VLS_intrinsics.p)({});
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.strong, __VLS_intrinsics.strong)({});
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.form, __VLS_intrinsics.form)({
|
||||
...{ onSubmit: (__VLS_ctx.run) },
|
||||
});
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.fieldset, __VLS_intrinsics.fieldset)({
|
||||
disabled: (__VLS_ctx.isBusy),
|
||||
});
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.legend, __VLS_intrinsics.legend)({});
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.label, __VLS_intrinsics.label)({});
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.input)({
|
||||
type: "checkbox",
|
||||
});
|
||||
(__VLS_ctx.hardImpairmentApproved);
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.label, __VLS_intrinsics.label)({});
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.input)({
|
||||
type: "checkbox",
|
||||
});
|
||||
(__VLS_ctx.capitalFloorBreached);
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.label, __VLS_intrinsics.label)({});
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.input)({
|
||||
type: "number",
|
||||
min: "0",
|
||||
step: "0.1",
|
||||
});
|
||||
(__VLS_ctx.gapBelowFloorAtr);
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.label, __VLS_intrinsics.label)({});
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.input)({
|
||||
type: "number",
|
||||
min: "0",
|
||||
step: "1",
|
||||
});
|
||||
(__VLS_ctx.consecutiveCloseBreaches);
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.button, __VLS_intrinsics.button)({
|
||||
type: "submit",
|
||||
});
|
||||
const __VLS_0 = QueryStateBoundary || QueryStateBoundary;
|
||||
// @ts-ignore
|
||||
const __VLS_1 = __VLS_asFunctionalComponent1(__VLS_0, new __VLS_0({
|
||||
...{ 'onRetry': {} },
|
||||
loading: (__VLS_ctx.isBusy),
|
||||
error: __VLS_ctx.mutation.error.value,
|
||||
empty: (!__VLS_ctx.mutation.data.value),
|
||||
}));
|
||||
const __VLS_2 = __VLS_1({
|
||||
...{ 'onRetry': {} },
|
||||
loading: (__VLS_ctx.isBusy),
|
||||
error: __VLS_ctx.mutation.error.value,
|
||||
empty: (!__VLS_ctx.mutation.data.value),
|
||||
}, ...__VLS_functionalComponentArgsRest(__VLS_1));
|
||||
let __VLS_5;
|
||||
const __VLS_6 = {
|
||||
/** @type {typeof __VLS_5.retry} */
|
||||
onRetry: (__VLS_ctx.retry),
|
||||
};
|
||||
const { default: __VLS_7 } = __VLS_3.slots;
|
||||
if (__VLS_ctx.mutation.data.value) {
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.dl, __VLS_intrinsics.dl)({});
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.dt, __VLS_intrinsics.dt)({});
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.dd, __VLS_intrinsics.dd)({});
|
||||
(__VLS_ctx.mutation.data.value.action);
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.dt, __VLS_intrinsics.dt)({});
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.dd, __VLS_intrinsics.dd)({});
|
||||
(__VLS_ctx.mutation.data.value.policyId);
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.dt, __VLS_intrinsics.dt)({});
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.dd, __VLS_intrinsics.dd)({});
|
||||
(__VLS_ctx.mutation.data.value.reasonCode);
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.dt, __VLS_intrinsics.dt)({});
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.dd, __VLS_intrinsics.dd)({});
|
||||
(__VLS_ctx.mutation.data.value.sellRatioOfLot);
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.dt, __VLS_intrinsics.dt)({});
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.dd, __VLS_intrinsics.dd)({});
|
||||
(__VLS_ctx.mutation.data.value.targetSecurityPortfolioWeightAfter);
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.dt, __VLS_intrinsics.dt)({});
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.dd, __VLS_intrinsics.dd)({});
|
||||
(__VLS_ctx.mutation.data.value.reentryEligible);
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.dt, __VLS_intrinsics.dt)({});
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.dd, __VLS_intrinsics.dd)({});
|
||||
(__VLS_ctx.mutation.data.value.decisionContractVersion);
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.dt, __VLS_intrinsics.dt)({});
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.dd, __VLS_intrinsics.dd)({});
|
||||
(__VLS_ctx.mutation.data.value.policyTrace.length);
|
||||
}
|
||||
if (__VLS_ctx.mutation.data.value) {
|
||||
const __VLS_8 = PolicyTracePanel;
|
||||
// @ts-ignore
|
||||
const __VLS_9 = __VLS_asFunctionalComponent1(__VLS_8, new __VLS_8({
|
||||
entries: (__VLS_ctx.mutation.data.value.policyTrace),
|
||||
schemaVersion: (__VLS_ctx.mutation.data.value.policyTraceSchemaVersion),
|
||||
}));
|
||||
const __VLS_10 = __VLS_9({
|
||||
entries: (__VLS_ctx.mutation.data.value.policyTrace),
|
||||
schemaVersion: (__VLS_ctx.mutation.data.value.policyTraceSchemaVersion),
|
||||
}, ...__VLS_functionalComponentArgsRest(__VLS_9));
|
||||
}
|
||||
// @ts-ignore
|
||||
[run, isBusy, isBusy, hardImpairmentApproved, capitalFloorBreached, gapBelowFloorAtr, consecutiveCloseBreaches, mutation, mutation, mutation, mutation, mutation, mutation, mutation, mutation, mutation, mutation, mutation, mutation, mutation, mutation, retry,];
|
||||
var __VLS_3;
|
||||
var __VLS_4;
|
||||
// @ts-ignore
|
||||
[];
|
||||
const __VLS_export = (await import('vue')).defineComponent({});
|
||||
export default {};
|
||||
@@ -0,0 +1,5 @@
|
||||
import { useMutation } from '@tanstack/vue-query';
|
||||
import { evaluateResearchSellPolicy } from './api';
|
||||
export function useEvaluateResearchSellPolicy() {
|
||||
return useMutation({ mutationFn: evaluateResearchSellPolicy });
|
||||
}
|
||||
@@ -0,0 +1,61 @@
|
||||
import { z } from 'zod';
|
||||
const ratio = z.number().min(0).max(1);
|
||||
const policyTraceEntrySchema = z.object({
|
||||
policyId: z.string().min(1),
|
||||
priority: z.number().int(),
|
||||
disposition: z.union([z.literal(0), z.literal(1), z.literal(2)]),
|
||||
reasonCode: z.string().min(1),
|
||||
requestedSellRatioOfLot: ratio,
|
||||
appliedSellRatioOfLot: ratio,
|
||||
strategicCoreClampApplied: z.boolean()
|
||||
});
|
||||
export const researchSellPolicyRequestSchema = z.object({
|
||||
positionLotId: z.string().uuid(),
|
||||
cycleId: z.string().uuid(),
|
||||
evidenceId: z.string().min(1).max(128),
|
||||
datasetId: z.string().min(1).max(128),
|
||||
modelVersion: z.string().min(1).max(128),
|
||||
configVersion: z.string().min(1).max(128),
|
||||
codeSha: z.string().min(1).max(128),
|
||||
asOf: z.string().datetime({ offset: true }),
|
||||
publishedAtCutoff: z.string().datetime({ offset: true }),
|
||||
currentSecurityPortfolioWeight: ratio,
|
||||
currentLotPortfolioWeight: ratio,
|
||||
strategicCoreFloorWeight: ratio,
|
||||
hardImpairmentApproved: z.boolean(),
|
||||
capitalFloorBreached: z.boolean(),
|
||||
survivalSellRatioOfLot: ratio,
|
||||
gapBelowFloorAtr: z.number().min(0),
|
||||
consecutiveCloseBreaches: z.number().int().min(0),
|
||||
cooldownSatisfied: z.boolean(),
|
||||
concentrationSellRatioOfLot: ratio,
|
||||
opportunityEdgeLowerBound: z.number(),
|
||||
opportunitySellRatioOfLot: ratio
|
||||
}).superRefine((value, ctx) => {
|
||||
if (value.currentLotPortfolioWeight > value.currentSecurityPortfolioWeight) {
|
||||
ctx.addIssue({
|
||||
code: z.ZodIssueCode.custom,
|
||||
message: 'Lot 비중은 종목 전체 비중을 초과할 수 없습니다.',
|
||||
path: ['currentLotPortfolioWeight']
|
||||
});
|
||||
}
|
||||
if (new Date(value.publishedAtCutoff) > new Date(value.asOf)) {
|
||||
ctx.addIssue({
|
||||
code: z.ZodIssueCode.custom,
|
||||
message: '공개 가능 시각은 평가 시각 이후일 수 없습니다.',
|
||||
path: ['publishedAtCutoff']
|
||||
});
|
||||
}
|
||||
});
|
||||
export const researchSellPolicyResponseSchema = z.object({
|
||||
action: z.enum(['Hold', 'PartialSell', 'FullSell']),
|
||||
sellRatioOfLot: ratio,
|
||||
targetSecurityPortfolioWeightAfter: ratio,
|
||||
policyId: z.string().min(1),
|
||||
reasonCode: z.string().min(1),
|
||||
decisionContractVersion: z.literal('sell-decision.v2'),
|
||||
policyTraceSchemaVersion: z.literal(2),
|
||||
reentryEligible: z.boolean(),
|
||||
policyTrace: z.array(policyTraceEntrySchema),
|
||||
evidenceStatus: z.literal('RESEARCH_CANDIDATE_NOT_PRODUCTION')
|
||||
});
|
||||
@@ -0,0 +1,57 @@
|
||||
import { describe, expect, it } from 'vitest';
|
||||
import { researchSellPolicyRequestSchema, researchSellPolicyResponseSchema } from '../schema';
|
||||
const baseRequest = {
|
||||
positionLotId: '00000000-0000-0000-0000-000000000001',
|
||||
cycleId: '00000000-0000-0000-0000-000000000002',
|
||||
evidenceId: 'evidence-1',
|
||||
datasetId: 'dataset-1',
|
||||
modelVersion: 'model-1',
|
||||
configVersion: 'config-1',
|
||||
codeSha: 'sha-1',
|
||||
asOf: '2026-08-01T07:00:00Z',
|
||||
publishedAtCutoff: '2026-08-01T06:00:00Z',
|
||||
currentSecurityPortfolioWeight: 0.6,
|
||||
currentLotPortfolioWeight: 0.2,
|
||||
strategicCoreFloorWeight: 0.3,
|
||||
hardImpairmentApproved: false,
|
||||
capitalFloorBreached: false,
|
||||
survivalSellRatioOfLot: 0,
|
||||
gapBelowFloorAtr: 0,
|
||||
consecutiveCloseBreaches: 0,
|
||||
cooldownSatisfied: true,
|
||||
concentrationSellRatioOfLot: 0,
|
||||
opportunityEdgeLowerBound: 0,
|
||||
opportunitySellRatioOfLot: 0
|
||||
};
|
||||
describe('research sell policy contracts', () => {
|
||||
it('accepts a valid point-in-time request', () => {
|
||||
expect(researchSellPolicyRequestSchema.safeParse(baseRequest).success).toBe(true);
|
||||
});
|
||||
it('rejects a lot weight above security weight', () => {
|
||||
const result = researchSellPolicyRequestSchema.safeParse({
|
||||
...baseRequest,
|
||||
currentLotPortfolioWeight: 0.7
|
||||
});
|
||||
expect(result.success).toBe(false);
|
||||
});
|
||||
it('rejects a future published-at cutoff', () => {
|
||||
const result = researchSellPolicyRequestSchema.safeParse({
|
||||
...baseRequest,
|
||||
publishedAtCutoff: '2026-08-01T08:00:00Z'
|
||||
});
|
||||
expect(result.success).toBe(false);
|
||||
});
|
||||
it('rejects an unknown production status', () => {
|
||||
const result = researchSellPolicyResponseSchema.safeParse({
|
||||
action: 'Hold',
|
||||
sellRatioOfLot: 0,
|
||||
targetSecurityPortfolioWeightAfter: 0.6,
|
||||
policyId: 'ALG-HOLD-001',
|
||||
reasonCode: 'NO_SELL_CONDITION',
|
||||
reentryEligible: false,
|
||||
policyTrace: [],
|
||||
evidenceStatus: 'PRODUCTION'
|
||||
});
|
||||
expect(result.success).toBe(false);
|
||||
});
|
||||
});
|
||||
@@ -0,0 +1,185 @@
|
||||
import { computed, ref } from 'vue';
|
||||
import { SearchListCrudPage } from '@/shared/ui/screen-types';
|
||||
import { screenTemplateCatalogue } from '@/shared/ui/screen-types/catalogue';
|
||||
import { KsButton, KsDataGrid, KsSelect, KsStatusTag, KsTextField } from '@/shared/ui/components';
|
||||
import { useUiAdapter } from '@/shared/ui/adapter/useUiAdapter';
|
||||
const adapter = useUiAdapter();
|
||||
const query = ref('');
|
||||
const status = ref('ALL');
|
||||
const options = [{ label: '전체', value: 'ALL' }, { label: '검토 필요', value: 'REVIEW' }, { label: '보류', value: 'HOLD' }];
|
||||
const rows = computed(() => screenTemplateCatalogue.filter(x => !query.value || `${x.id} ${x.name} ${x.component}`.toLowerCase().includes(query.value.toLowerCase())).map(x => ({ id: x.id, name: x.name, component: x.component, evidence: x.mandatoryEvidence.length, state: 'READY' })));
|
||||
const columns = [{ field: 'id', header: '화면 ID', width: 100 }, { field: 'name', header: '화면 타입' }, { field: 'component', header: '표준 컴포넌트', minWidth: 220 }, { field: 'evidence', header: '필수 증거', width: 110 }, { field: 'state', header: '상태', width: 110 }];
|
||||
const __VLS_ctx = {
|
||||
...{},
|
||||
...{},
|
||||
};
|
||||
let __VLS_components;
|
||||
let __VLS_intrinsics;
|
||||
let __VLS_directives;
|
||||
/** @type {__VLS_StyleScopedClasses['summary']} */ ;
|
||||
/** @type {__VLS_StyleScopedClasses['summary']} */ ;
|
||||
/** @type {__VLS_StyleScopedClasses['detail']} */ ;
|
||||
/** @type {__VLS_StyleScopedClasses['filters']} */ ;
|
||||
let __VLS_0;
|
||||
/** @ts-ignore @type { | typeof __VLS_components.SearchListCrudPage | typeof __VLS_components.SearchListCrudPage} */
|
||||
SearchListCrudPage;
|
||||
// @ts-ignore
|
||||
const __VLS_1 = __VLS_asFunctionalComponent1(__VLS_0, new __VLS_0({
|
||||
title: "표준 UI 패턴",
|
||||
subtitle: "Feature는 공급자 라이브러리를 직접 사용하지 않고, v2 어댑터·레이아웃·화면 계약을 사용한다.",
|
||||
state: "READY",
|
||||
evidence: ({ asOf: '2026-08-02', version: 'UI-CONTRACT-2.0' }),
|
||||
}));
|
||||
const __VLS_2 = __VLS_1({
|
||||
title: "표준 UI 패턴",
|
||||
subtitle: "Feature는 공급자 라이브러리를 직접 사용하지 않고, v2 어댑터·레이아웃·화면 계약을 사용한다.",
|
||||
state: "READY",
|
||||
evidence: ({ asOf: '2026-08-02', version: 'UI-CONTRACT-2.0' }),
|
||||
}, ...__VLS_functionalComponentArgsRest(__VLS_1));
|
||||
var __VLS_5;
|
||||
const { default: __VLS_6 } = __VLS_3.slots;
|
||||
{
|
||||
const { actions: __VLS_7 } = __VLS_3.slots;
|
||||
let __VLS_8;
|
||||
/** @ts-ignore @type { | typeof __VLS_components.KsButton} */
|
||||
KsButton;
|
||||
// @ts-ignore
|
||||
const __VLS_9 = __VLS_asFunctionalComponent1(__VLS_8, new __VLS_8({
|
||||
label: "새 화면 패킷",
|
||||
severity: "secondary",
|
||||
}));
|
||||
const __VLS_10 = __VLS_9({
|
||||
label: "새 화면 패킷",
|
||||
severity: "secondary",
|
||||
}, ...__VLS_functionalComponentArgsRest(__VLS_9));
|
||||
}
|
||||
{
|
||||
const { summary: __VLS_13 } = __VLS_3.slots;
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.div, __VLS_intrinsics.div)({
|
||||
...{ class: "ks-card summary" },
|
||||
});
|
||||
/** @type {__VLS_StyleScopedClasses['ks-card']} */ ;
|
||||
/** @type {__VLS_StyleScopedClasses['summary']} */ ;
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.strong, __VLS_intrinsics.strong)({});
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.span, __VLS_intrinsics.span)({});
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.div, __VLS_intrinsics.div)({
|
||||
...{ class: "ks-card summary" },
|
||||
});
|
||||
/** @type {__VLS_StyleScopedClasses['ks-card']} */ ;
|
||||
/** @type {__VLS_StyleScopedClasses['summary']} */ ;
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.strong, __VLS_intrinsics.strong)({});
|
||||
(__VLS_ctx.adapter.descriptor.capabilities.size);
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.span, __VLS_intrinsics.span)({});
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.div, __VLS_intrinsics.div)({
|
||||
...{ class: "ks-card summary" },
|
||||
});
|
||||
/** @type {__VLS_StyleScopedClasses['ks-card']} */ ;
|
||||
/** @type {__VLS_StyleScopedClasses['summary']} */ ;
|
||||
let __VLS_14;
|
||||
/** @ts-ignore @type { | typeof __VLS_components.KsStatusTag} */
|
||||
KsStatusTag;
|
||||
// @ts-ignore
|
||||
const __VLS_15 = __VLS_asFunctionalComponent1(__VLS_14, new __VLS_14({
|
||||
value: (__VLS_ctx.adapter.descriptor.id),
|
||||
severity: "info",
|
||||
}));
|
||||
const __VLS_16 = __VLS_15({
|
||||
value: (__VLS_ctx.adapter.descriptor.id),
|
||||
severity: "info",
|
||||
}, ...__VLS_functionalComponentArgsRest(__VLS_15));
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.span, __VLS_intrinsics.span)({});
|
||||
(__VLS_ctx.adapter.descriptor.vendor);
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.div, __VLS_intrinsics.div)({
|
||||
...{ class: "ks-card summary" },
|
||||
});
|
||||
/** @type {__VLS_StyleScopedClasses['ks-card']} */ ;
|
||||
/** @type {__VLS_StyleScopedClasses['summary']} */ ;
|
||||
let __VLS_19;
|
||||
/** @ts-ignore @type { | typeof __VLS_components.KsStatusTag} */
|
||||
KsStatusTag;
|
||||
// @ts-ignore
|
||||
const __VLS_20 = __VLS_asFunctionalComponent1(__VLS_19, new __VLS_19({
|
||||
value: "자동주문 OFF",
|
||||
severity: "warning",
|
||||
}));
|
||||
const __VLS_21 = __VLS_20({
|
||||
value: "자동주문 OFF",
|
||||
severity: "warning",
|
||||
}, ...__VLS_functionalComponentArgsRest(__VLS_20));
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.span, __VLS_intrinsics.span)({});
|
||||
// @ts-ignore
|
||||
[adapter, adapter, adapter,];
|
||||
}
|
||||
{
|
||||
const { filters: __VLS_24 } = __VLS_3.slots;
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.div, __VLS_intrinsics.div)({
|
||||
...{ class: "filters" },
|
||||
});
|
||||
/** @type {__VLS_StyleScopedClasses['filters']} */ ;
|
||||
let __VLS_25;
|
||||
/** @ts-ignore @type { | typeof __VLS_components.KsTextField} */
|
||||
KsTextField;
|
||||
// @ts-ignore
|
||||
const __VLS_26 = __VLS_asFunctionalComponent1(__VLS_25, new __VLS_25({
|
||||
modelValue: (__VLS_ctx.query),
|
||||
label: "검색",
|
||||
placeholder: "화면 ID, 타입 또는 컴포넌트",
|
||||
}));
|
||||
const __VLS_27 = __VLS_26({
|
||||
modelValue: (__VLS_ctx.query),
|
||||
label: "검색",
|
||||
placeholder: "화면 ID, 타입 또는 컴포넌트",
|
||||
}, ...__VLS_functionalComponentArgsRest(__VLS_26));
|
||||
let __VLS_30;
|
||||
/** @ts-ignore @type { | typeof __VLS_components.KsSelect} */
|
||||
KsSelect;
|
||||
// @ts-ignore
|
||||
const __VLS_31 = __VLS_asFunctionalComponent1(__VLS_30, new __VLS_30({
|
||||
modelValue: (__VLS_ctx.status),
|
||||
label: "상태",
|
||||
options: (__VLS_ctx.options),
|
||||
}));
|
||||
const __VLS_32 = __VLS_31({
|
||||
modelValue: (__VLS_ctx.status),
|
||||
label: "상태",
|
||||
options: (__VLS_ctx.options),
|
||||
}, ...__VLS_functionalComponentArgsRest(__VLS_31));
|
||||
// @ts-ignore
|
||||
[query, status, options,];
|
||||
}
|
||||
let __VLS_35;
|
||||
/** @ts-ignore @type { | typeof __VLS_components.KsDataGrid} */
|
||||
KsDataGrid;
|
||||
// @ts-ignore
|
||||
const __VLS_36 = __VLS_asFunctionalComponent1(__VLS_35, new __VLS_35({
|
||||
rows: (__VLS_ctx.rows),
|
||||
columns: (__VLS_ctx.columns),
|
||||
height: "25rem",
|
||||
}));
|
||||
const __VLS_37 = __VLS_36({
|
||||
rows: (__VLS_ctx.rows),
|
||||
columns: (__VLS_ctx.columns),
|
||||
height: "25rem",
|
||||
}, ...__VLS_functionalComponentArgsRest(__VLS_36));
|
||||
{
|
||||
const { detail: __VLS_40 } = __VLS_3.slots;
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.div, __VLS_intrinsics.div)({
|
||||
...{ class: "ks-card detail" },
|
||||
});
|
||||
/** @type {__VLS_StyleScopedClasses['ks-card']} */ ;
|
||||
/** @type {__VLS_StyleScopedClasses['detail']} */ ;
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.h2, __VLS_intrinsics.h2)({});
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.p, __VLS_intrinsics.p)({});
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.code, __VLS_intrinsics.code)({});
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.p, __VLS_intrinsics.p)({});
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.p, __VLS_intrinsics.p)({});
|
||||
// @ts-ignore
|
||||
[rows, columns,];
|
||||
}
|
||||
// @ts-ignore
|
||||
[];
|
||||
var __VLS_3;
|
||||
// @ts-ignore
|
||||
[];
|
||||
const __VLS_export = (await import('vue')).defineComponent({});
|
||||
export default {};
|
||||
@@ -0,0 +1,14 @@
|
||||
import { createApp } from 'vue';
|
||||
import { createPinia } from 'pinia';
|
||||
import { VueQueryPlugin } from '@tanstack/vue-query';
|
||||
import App from './App.vue';
|
||||
import { router } from './app/router';
|
||||
import { queryClient } from './app/queryClient';
|
||||
import { resolveUiProvider } from './shared/ui/provider';
|
||||
import './design-system/base.css';
|
||||
const app = createApp(App);
|
||||
app.use(createPinia());
|
||||
app.use(router);
|
||||
app.use(VueQueryPlugin, { queryClient });
|
||||
resolveUiProvider(import.meta.env.VITE_UI_ADAPTER).install(app);
|
||||
app.mount('#app');
|
||||
@@ -0,0 +1,18 @@
|
||||
import axios from 'axios';
|
||||
import { ApiProblem } from './problem';
|
||||
export const api = axios.create({ baseURL: '/api', timeout: 15_000 });
|
||||
api.interceptors.request.use(config => {
|
||||
const user = import.meta.env.VITE_DEV_AUTH_USER;
|
||||
const role = import.meta.env.VITE_DEV_AUTH_ROLE;
|
||||
if (import.meta.env.DEV && user && role) {
|
||||
config.headers['X-KArtSell-User'] = user;
|
||||
config.headers['X-KArtSell-Role'] = role;
|
||||
}
|
||||
return config;
|
||||
});
|
||||
api.interceptors.response.use(response => response, error => {
|
||||
const data = error.response?.data;
|
||||
if (data?.status)
|
||||
throw new ApiProblem(data);
|
||||
throw error;
|
||||
});
|
||||
@@ -0,0 +1,8 @@
|
||||
export class ApiProblem extends Error {
|
||||
problem;
|
||||
constructor(problem) {
|
||||
super(problem.title);
|
||||
this.problem = problem;
|
||||
}
|
||||
get status() { return this.problem.status; }
|
||||
}
|
||||
@@ -0,0 +1,25 @@
|
||||
const props = defineProps();
|
||||
const __VLS_ctx = {
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
};
|
||||
let __VLS_components;
|
||||
let __VLS_intrinsics;
|
||||
let __VLS_directives;
|
||||
if (props.allowed) {
|
||||
var __VLS_0 = {};
|
||||
}
|
||||
else {
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.p, __VLS_intrinsics.p)({
|
||||
role: "alert",
|
||||
});
|
||||
(props.deniedMessage ?? '이 기능을 사용할 권한이 없습니다.');
|
||||
}
|
||||
// @ts-ignore
|
||||
var __VLS_1 = __VLS_0;
|
||||
const __VLS_base = (await import('vue')).defineComponent({
|
||||
__typeProps: {},
|
||||
});
|
||||
const __VLS_export = {};
|
||||
export default {};
|
||||
@@ -0,0 +1,9 @@
|
||||
export function createIdempotencyKey() {
|
||||
return crypto.randomUUID();
|
||||
}
|
||||
/**
|
||||
* Create once per user intent. Retries must reuse the returned envelope rather than call this again.
|
||||
*/
|
||||
export function createIdempotentCommand(request) {
|
||||
return Object.freeze({ idempotencyKey: createIdempotencyKey(), request });
|
||||
}
|
||||
@@ -3,9 +3,13 @@ export interface IdempotentCommand<T> {
|
||||
readonly request: T
|
||||
}
|
||||
|
||||
export function createIdempotencyKey(): string {
|
||||
return crypto.randomUUID()
|
||||
}
|
||||
|
||||
/**
|
||||
* Create once per user intent. Retries must reuse the returned envelope rather than call this again.
|
||||
*/
|
||||
export function createIdempotentCommand<T>(request: T): IdempotentCommand<T> {
|
||||
return Object.freeze({ idempotencyKey: crypto.randomUUID(), request })
|
||||
return Object.freeze({ idempotencyKey: createIdempotencyKey(), request })
|
||||
}
|
||||
|
||||
@@ -0,0 +1,9 @@
|
||||
import { z } from 'zod';
|
||||
export const versionSetSchema = z.object({
|
||||
datasetId: z.string().min(1).max(128),
|
||||
dataHash: z.string().min(1).max(128),
|
||||
modelVersion: z.string().min(1).max(128),
|
||||
configVersion: z.string().min(1).max(128),
|
||||
codeSha: z.string().min(1).max(128),
|
||||
contractVersion: z.string().min(1).max(64)
|
||||
});
|
||||
@@ -0,0 +1,111 @@
|
||||
import PageLayout from '../ui/layouts/PageLayout.vue';
|
||||
import FormPageLayout from '../ui/layouts/FormPageLayout.vue';
|
||||
import StandardScreenBoundary from '../ui/screen-types/v2/StandardScreenBoundary.vue';
|
||||
const __VLS_props = withDefaults(defineProps(), { state: 'READY', dirty: false, readonly: false });
|
||||
const emit = defineEmits();
|
||||
const __VLS_defaults = { state: 'READY', dirty: false, readonly: false };
|
||||
const __VLS_ctx = {
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
};
|
||||
let __VLS_components;
|
||||
let __VLS_intrinsics;
|
||||
let __VLS_directives;
|
||||
const __VLS_0 = PageLayout || PageLayout;
|
||||
// @ts-ignore
|
||||
const __VLS_1 = __VLS_asFunctionalComponent1(__VLS_0, new __VLS_0({
|
||||
title: (__VLS_ctx.title),
|
||||
subtitle: (__VLS_ctx.subtitle),
|
||||
status: (__VLS_ctx.readonly ? 'READONLY' : __VLS_ctx.state),
|
||||
asOf: (__VLS_ctx.asOf),
|
||||
version: (__VLS_ctx.version),
|
||||
}));
|
||||
const __VLS_2 = __VLS_1({
|
||||
title: (__VLS_ctx.title),
|
||||
subtitle: (__VLS_ctx.subtitle),
|
||||
status: (__VLS_ctx.readonly ? 'READONLY' : __VLS_ctx.state),
|
||||
asOf: (__VLS_ctx.asOf),
|
||||
version: (__VLS_ctx.version),
|
||||
}, ...__VLS_functionalComponentArgsRest(__VLS_1));
|
||||
var __VLS_5;
|
||||
const { default: __VLS_6 } = __VLS_3.slots;
|
||||
const __VLS_7 = StandardScreenBoundary || StandardScreenBoundary;
|
||||
// @ts-ignore
|
||||
const __VLS_8 = __VLS_asFunctionalComponent1(__VLS_7, new __VLS_7({
|
||||
...{ 'onRetry': {} },
|
||||
state: (__VLS_ctx.readonly ? 'READONLY' : (__VLS_ctx.dirty ? 'DIRTY' : __VLS_ctx.state)),
|
||||
staleAt: (__VLS_ctx.asOf),
|
||||
}));
|
||||
const __VLS_9 = __VLS_8({
|
||||
...{ 'onRetry': {} },
|
||||
state: (__VLS_ctx.readonly ? 'READONLY' : (__VLS_ctx.dirty ? 'DIRTY' : __VLS_ctx.state)),
|
||||
staleAt: (__VLS_ctx.asOf),
|
||||
}, ...__VLS_functionalComponentArgsRest(__VLS_8));
|
||||
let __VLS_12;
|
||||
const __VLS_13 = {
|
||||
/** @type {typeof __VLS_12.retry} */
|
||||
onRetry: (...[$event]) => {
|
||||
return (__VLS_ctx.emit('retry'));
|
||||
// @ts-ignore
|
||||
[title, subtitle, readonly, readonly, state, state, asOf, asOf, version, dirty, emit,];
|
||||
},
|
||||
};
|
||||
const { default: __VLS_14 } = __VLS_10.slots;
|
||||
const __VLS_15 = FormPageLayout || FormPageLayout;
|
||||
// @ts-ignore
|
||||
const __VLS_16 = __VLS_asFunctionalComponent1(__VLS_15, new __VLS_15({
|
||||
...{ 'onSubmit': {} },
|
||||
}));
|
||||
const __VLS_17 = __VLS_16({
|
||||
...{ 'onSubmit': {} },
|
||||
}, ...__VLS_functionalComponentArgsRest(__VLS_16));
|
||||
let __VLS_20;
|
||||
const __VLS_21 = {
|
||||
/** @type {typeof __VLS_20.submit} */
|
||||
onSubmit: (...[$event]) => {
|
||||
return (__VLS_ctx.emit('submit'));
|
||||
// @ts-ignore
|
||||
[emit,];
|
||||
},
|
||||
};
|
||||
const { default: __VLS_22 } = __VLS_18.slots;
|
||||
var __VLS_23 = {};
|
||||
if (__VLS_ctx.$slots.aside) {
|
||||
{
|
||||
const { preview: __VLS_25 } = __VLS_18.slots;
|
||||
var __VLS_26 = {};
|
||||
// @ts-ignore
|
||||
[$slots,];
|
||||
}
|
||||
}
|
||||
// @ts-ignore
|
||||
[];
|
||||
var __VLS_18;
|
||||
var __VLS_19;
|
||||
// @ts-ignore
|
||||
[];
|
||||
var __VLS_10;
|
||||
var __VLS_11;
|
||||
{
|
||||
const { footer: __VLS_28 } = __VLS_3.slots;
|
||||
var __VLS_29 = {};
|
||||
// @ts-ignore
|
||||
[];
|
||||
}
|
||||
// @ts-ignore
|
||||
[];
|
||||
var __VLS_3;
|
||||
// @ts-ignore
|
||||
var __VLS_24 = __VLS_23, __VLS_27 = __VLS_26, __VLS_30 = __VLS_29;
|
||||
// @ts-ignore
|
||||
[];
|
||||
const __VLS_base = (await import('vue')).defineComponent({
|
||||
__typeEmits: {},
|
||||
__typeProps: {},
|
||||
props: {},
|
||||
});
|
||||
const __VLS_export = {};
|
||||
export default {};
|
||||
@@ -0,0 +1,159 @@
|
||||
import PageLayout from '../ui/layouts/PageLayout.vue';
|
||||
import StandardScreenBoundary from '../ui/screen-types/v2/StandardScreenBoundary.vue';
|
||||
import KsDataGrid from '../ui/components/KsDataGrid.vue';
|
||||
import KsPaginator from '../ui/components/KsPaginator.vue';
|
||||
const __VLS_props = withDefaults(defineProps(), { state: 'READY', rows: () => [] });
|
||||
const emit = defineEmits();
|
||||
const __VLS_defaults = { state: 'READY', rows: () => [] };
|
||||
const __VLS_ctx = {
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
};
|
||||
let __VLS_components;
|
||||
let __VLS_intrinsics;
|
||||
let __VLS_directives;
|
||||
const __VLS_0 = PageLayout || PageLayout;
|
||||
// @ts-ignore
|
||||
const __VLS_1 = __VLS_asFunctionalComponent1(__VLS_0, new __VLS_0({
|
||||
title: (__VLS_ctx.title),
|
||||
subtitle: (__VLS_ctx.subtitle),
|
||||
status: (__VLS_ctx.state),
|
||||
asOf: (__VLS_ctx.asOf),
|
||||
version: (__VLS_ctx.version),
|
||||
}));
|
||||
const __VLS_2 = __VLS_1({
|
||||
title: (__VLS_ctx.title),
|
||||
subtitle: (__VLS_ctx.subtitle),
|
||||
status: (__VLS_ctx.state),
|
||||
asOf: (__VLS_ctx.asOf),
|
||||
version: (__VLS_ctx.version),
|
||||
}, ...__VLS_functionalComponentArgsRest(__VLS_1));
|
||||
var __VLS_5;
|
||||
const { default: __VLS_6 } = __VLS_3.slots;
|
||||
{
|
||||
const { actions: __VLS_7 } = __VLS_3.slots;
|
||||
var __VLS_8 = {};
|
||||
// @ts-ignore
|
||||
[title, subtitle, state, asOf, version,];
|
||||
}
|
||||
{
|
||||
const { summary: __VLS_10 } = __VLS_3.slots;
|
||||
var __VLS_11 = {};
|
||||
// @ts-ignore
|
||||
[];
|
||||
}
|
||||
{
|
||||
const { filters: __VLS_13 } = __VLS_3.slots;
|
||||
var __VLS_14 = {};
|
||||
// @ts-ignore
|
||||
[];
|
||||
}
|
||||
const __VLS_16 = StandardScreenBoundary || StandardScreenBoundary;
|
||||
// @ts-ignore
|
||||
const __VLS_17 = __VLS_asFunctionalComponent1(__VLS_16, new __VLS_16({
|
||||
...{ 'onRetry': {} },
|
||||
state: (__VLS_ctx.state),
|
||||
warning: (__VLS_ctx.warning),
|
||||
staleAt: (__VLS_ctx.asOf),
|
||||
}));
|
||||
const __VLS_18 = __VLS_17({
|
||||
...{ 'onRetry': {} },
|
||||
state: (__VLS_ctx.state),
|
||||
warning: (__VLS_ctx.warning),
|
||||
staleAt: (__VLS_ctx.asOf),
|
||||
}, ...__VLS_functionalComponentArgsRest(__VLS_17));
|
||||
let __VLS_21;
|
||||
const __VLS_22 = {
|
||||
/** @type {typeof __VLS_21.retry} */
|
||||
onRetry: (...[$event]) => {
|
||||
return (__VLS_ctx.emit('retry'));
|
||||
// @ts-ignore
|
||||
[state, asOf, warning, emit,];
|
||||
},
|
||||
};
|
||||
const { default: __VLS_23 } = __VLS_19.slots;
|
||||
const __VLS_24 = KsDataGrid;
|
||||
// @ts-ignore
|
||||
const __VLS_25 = __VLS_asFunctionalComponent1(__VLS_24, new __VLS_24({
|
||||
...{ 'onRowSelected': {} },
|
||||
rows: (__VLS_ctx.rows),
|
||||
columns: (__VLS_ctx.columns),
|
||||
}));
|
||||
const __VLS_26 = __VLS_25({
|
||||
...{ 'onRowSelected': {} },
|
||||
rows: (__VLS_ctx.rows),
|
||||
columns: (__VLS_ctx.columns),
|
||||
}, ...__VLS_functionalComponentArgsRest(__VLS_25));
|
||||
let __VLS_29;
|
||||
const __VLS_30 = {
|
||||
/** @type {typeof __VLS_29.rowSelected} */
|
||||
onRowSelected: (...[$event]) => {
|
||||
return (__VLS_ctx.emit('rowSelected', $event));
|
||||
// @ts-ignore
|
||||
[emit, rows, columns,];
|
||||
},
|
||||
};
|
||||
var __VLS_27;
|
||||
var __VLS_28;
|
||||
const __VLS_31 = KsPaginator;
|
||||
// @ts-ignore
|
||||
const __VLS_32 = __VLS_asFunctionalComponent1(__VLS_31, new __VLS_31({
|
||||
...{ 'onPageChange': {} },
|
||||
page: (__VLS_ctx.page),
|
||||
pageSize: (__VLS_ctx.pageSize),
|
||||
total: (__VLS_ctx.total),
|
||||
}));
|
||||
const __VLS_33 = __VLS_32({
|
||||
...{ 'onPageChange': {} },
|
||||
page: (__VLS_ctx.page),
|
||||
pageSize: (__VLS_ctx.pageSize),
|
||||
total: (__VLS_ctx.total),
|
||||
}, ...__VLS_functionalComponentArgsRest(__VLS_32));
|
||||
let __VLS_36;
|
||||
const __VLS_37 = {
|
||||
/** @type {typeof __VLS_36.pageChange} */
|
||||
onPageChange: (...[$event]) => {
|
||||
return (__VLS_ctx.emit('pageChange', $event));
|
||||
// @ts-ignore
|
||||
[emit, page, pageSize, total,];
|
||||
},
|
||||
};
|
||||
var __VLS_34;
|
||||
var __VLS_35;
|
||||
// @ts-ignore
|
||||
[];
|
||||
var __VLS_19;
|
||||
var __VLS_20;
|
||||
if (__VLS_ctx.$slots.detail) {
|
||||
{
|
||||
const { aside: __VLS_38 } = __VLS_3.slots;
|
||||
var __VLS_39 = {};
|
||||
// @ts-ignore
|
||||
[$slots,];
|
||||
}
|
||||
}
|
||||
if (__VLS_ctx.$slots.footer) {
|
||||
{
|
||||
const { footer: __VLS_41 } = __VLS_3.slots;
|
||||
var __VLS_42 = {};
|
||||
// @ts-ignore
|
||||
[$slots,];
|
||||
}
|
||||
}
|
||||
// @ts-ignore
|
||||
[];
|
||||
var __VLS_3;
|
||||
// @ts-ignore
|
||||
var __VLS_9 = __VLS_8, __VLS_12 = __VLS_11, __VLS_15 = __VLS_14, __VLS_40 = __VLS_39, __VLS_43 = __VLS_42;
|
||||
// @ts-ignore
|
||||
[];
|
||||
const __VLS_base = (await import('vue')).defineComponent({
|
||||
__typeEmits: {},
|
||||
__typeProps: {},
|
||||
props: {},
|
||||
});
|
||||
const __VLS_export = {};
|
||||
export default {};
|
||||
@@ -0,0 +1 @@
|
||||
export {};
|
||||
@@ -0,0 +1,41 @@
|
||||
const positiveInt = (value, fallback) => {
|
||||
const parsed = Number(value);
|
||||
return Number.isInteger(parsed) && parsed > 0 ? parsed : fallback;
|
||||
};
|
||||
export function decodeCrudQuery(params, fallback) {
|
||||
const sorts = params.getAll('sort').flatMap(value => {
|
||||
const parts = value.split(':');
|
||||
const field = parts[0];
|
||||
const direction = parts[1];
|
||||
if (field && (direction === 'asc' || direction === 'desc')) {
|
||||
return [{ field, direction: direction }];
|
||||
}
|
||||
return [];
|
||||
});
|
||||
const filters = params.getAll('filter').flatMap(value => {
|
||||
const first = value.indexOf(':');
|
||||
const second = value.indexOf(':', first + 1);
|
||||
if (first <= 0 || second <= first)
|
||||
return [];
|
||||
return [{ field: value.slice(0, first), operator: value.slice(first + 1, second), value: value.slice(second + 1) }];
|
||||
});
|
||||
return {
|
||||
page: positiveInt(params.get('page'), fallback.page),
|
||||
pageSize: positiveInt(params.get('pageSize'), fallback.pageSize),
|
||||
search: params.get('search')?.trim() || undefined,
|
||||
sorts: sorts.length ? sorts : fallback.sorts,
|
||||
filters: filters.length ? filters : fallback.filters
|
||||
};
|
||||
}
|
||||
export function encodeCrudQuery(query) {
|
||||
const params = new URLSearchParams();
|
||||
params.set('page', String(query.page));
|
||||
params.set('pageSize', String(query.pageSize));
|
||||
if (query.search)
|
||||
params.set('search', query.search);
|
||||
for (const sort of query.sorts)
|
||||
params.append('sort', `${sort.field}:${sort.direction}`);
|
||||
for (const filter of query.filters)
|
||||
params.append('filter', `${filter.field}:${filter.operator}:${String(filter.value ?? '')}`);
|
||||
return params;
|
||||
}
|
||||
@@ -7,8 +7,13 @@ const positiveInt = (value: string | null, fallback: number): number => {
|
||||
|
||||
export function decodeCrudQuery(params: URLSearchParams, fallback: CrudListQuery): CrudListQuery {
|
||||
const sorts = params.getAll('sort').flatMap(value => {
|
||||
const [field, direction] = value.split(':')
|
||||
return field && (direction === 'asc' || direction === 'desc') ? [{ field, direction }] : []
|
||||
const parts = value.split(':')
|
||||
const field = parts[0]
|
||||
const direction = parts[1]
|
||||
if (field && (direction === 'asc' || direction === 'desc')) {
|
||||
return [{ field, direction: direction as 'asc' | 'desc' }]
|
||||
}
|
||||
return []
|
||||
})
|
||||
const filters = params.getAll('filter').flatMap(value => {
|
||||
const first = value.indexOf(':')
|
||||
|
||||
@@ -0,0 +1,8 @@
|
||||
export function assertCrudResourceDefinition(definition) {
|
||||
if (!definition.resourceId.trim())
|
||||
throw new Error('resourceId is required');
|
||||
const fields = new Set(definition.columns.map(x => x.field));
|
||||
for (const sensitive of definition.sensitiveFields)
|
||||
if (!fields.has(sensitive))
|
||||
throw new Error(`Sensitive field '${sensitive}' has no grid column contract`);
|
||||
}
|
||||
@@ -0,0 +1,12 @@
|
||||
import { describe, expect, it } from 'vitest';
|
||||
import { decodeCrudQuery, encodeCrudQuery } from '../queryCodec';
|
||||
const fallback = { page: 1, pageSize: 20, sorts: [], filters: [] };
|
||||
describe('CRUD URL codec', () => {
|
||||
it('round-trips paging, sort, filter and search without hidden Pinia state', () => {
|
||||
const source = { page: 3, pageSize: 50, search: '005930', sorts: [{ field: 'asOf', direction: 'desc' }], filters: [{ field: 'status', operator: 'eq', value: 'WARN' }] };
|
||||
expect(decodeCrudQuery(encodeCrudQuery(source), fallback)).toEqual(source);
|
||||
});
|
||||
it('fails closed to approved defaults for invalid paging', () => {
|
||||
expect(decodeCrudQuery(new URLSearchParams('page=0&pageSize=-1'), fallback)).toEqual({ ...fallback, search: undefined });
|
||||
});
|
||||
});
|
||||
@@ -0,0 +1,20 @@
|
||||
import { computed, ref } from 'vue';
|
||||
export function useCrudListState(initial) {
|
||||
const query = ref({ ...initial, sorts: [...initial.sorts], filters: [...initial.filters] });
|
||||
const selectedId = ref(null);
|
||||
const dirty = ref(false);
|
||||
function replace(next) { query.value = { ...next, sorts: [...next.sorts], filters: [...next.filters] }; }
|
||||
function setPage(page, pageSize = query.value.pageSize) { query.value = { ...query.value, page, pageSize }; }
|
||||
function setSearch(search) { query.value = { ...query.value, page: 1, search: search?.trim() || undefined }; }
|
||||
function reset() { replace(initial); selectedId.value = null; dirty.value = false; }
|
||||
return {
|
||||
query,
|
||||
selectedId,
|
||||
dirty,
|
||||
offset: computed(() => (query.value.page - 1) * query.value.pageSize),
|
||||
replace,
|
||||
setPage,
|
||||
setSearch,
|
||||
reset
|
||||
};
|
||||
}
|
||||
@@ -0,0 +1,31 @@
|
||||
import { ref } from 'vue';
|
||||
import { createIdempotencyKey } from '../commands/idempotency';
|
||||
export function useOptimisticCommand(execute) {
|
||||
const pending = ref(false);
|
||||
const conflict = ref(false);
|
||||
const lastCorrelationId = ref();
|
||||
async function run(request) {
|
||||
if (pending.value)
|
||||
throw new Error('Command is already in progress');
|
||||
pending.value = true;
|
||||
conflict.value = false;
|
||||
try {
|
||||
const headers = { 'Idempotency-Key': createIdempotencyKey() };
|
||||
if (request.etag)
|
||||
headers['If-Match'] = request.etag;
|
||||
const response = await execute(request, headers);
|
||||
lastCorrelationId.value = response.correlationId;
|
||||
return response;
|
||||
}
|
||||
catch (error) {
|
||||
const status = error?.response?.status;
|
||||
if (status === 409 || status === 412)
|
||||
conflict.value = true;
|
||||
throw error;
|
||||
}
|
||||
finally {
|
||||
pending.value = false;
|
||||
}
|
||||
}
|
||||
return { pending, conflict, lastCorrelationId, run };
|
||||
}
|
||||
@@ -0,0 +1,23 @@
|
||||
export function formatCurrency(value, currency, locale = 'ko-KR') {
|
||||
if (value == null || Number.isNaN(value))
|
||||
return '—';
|
||||
return new Intl.NumberFormat(locale, { style: 'currency', currency, maximumFractionDigits: 2 }).format(value);
|
||||
}
|
||||
export function formatPercent(value, digits = 2, locale = 'ko-KR') {
|
||||
if (value == null || Number.isNaN(value))
|
||||
return '—';
|
||||
return new Intl.NumberFormat(locale, { style: 'percent', minimumFractionDigits: digits, maximumFractionDigits: digits }).format(value);
|
||||
}
|
||||
export function formatQuantity(value, digits = 4, locale = 'ko-KR') {
|
||||
if (value == null || Number.isNaN(value))
|
||||
return '—';
|
||||
return new Intl.NumberFormat(locale, { maximumFractionDigits: digits }).format(value);
|
||||
}
|
||||
export function formatAsOf(value, locale = 'ko-KR') {
|
||||
if (!value)
|
||||
return '—';
|
||||
const date = value instanceof Date ? value : new Date(value);
|
||||
if (Number.isNaN(date.getTime()))
|
||||
return '—';
|
||||
return new Intl.DateTimeFormat(locale, { dateStyle: 'medium', timeStyle: 'short', timeZone: 'Asia/Seoul' }).format(date);
|
||||
}
|
||||
@@ -0,0 +1,7 @@
|
||||
import { describe, expect, it } from 'vitest';
|
||||
import { formatCurrency, formatPercent, formatQuantity } from '../financial';
|
||||
describe('financial formatters', () => {
|
||||
it('renders missing values as an explicit em dash', () => { expect(formatCurrency(null, 'KRW')).toBe('—'); expect(formatPercent(undefined)).toBe('—'); });
|
||||
it('keeps percentage inputs in decimal-return units', () => { expect(formatPercent(0.125, 1)).toContain('12.5'); });
|
||||
it('uses bounded quantity precision', () => { expect(formatQuantity(1.234567, 2)).toContain('1.23'); });
|
||||
});
|
||||
@@ -0,0 +1,25 @@
|
||||
import { computed } from 'vue';
|
||||
const props = defineProps();
|
||||
const ageMinutes = computed(() => Math.max(0, (Date.now() - new Date(props.asOf).getTime()) / 60_000));
|
||||
const stale = computed(() => ageMinutes.value > props.staleAfterMinutes);
|
||||
const __VLS_ctx = {
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
};
|
||||
let __VLS_components;
|
||||
let __VLS_intrinsics;
|
||||
let __VLS_directives;
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.span, __VLS_intrinsics.span)({
|
||||
'aria-label': (__VLS_ctx.stale ? '데이터 지연' : '데이터 최신'),
|
||||
'data-status': (__VLS_ctx.stale ? 'stale' : 'fresh'),
|
||||
});
|
||||
(__VLS_ctx.stale ? 'STALE' : 'FRESH');
|
||||
(new Date(props.asOf).toLocaleString());
|
||||
// @ts-ignore
|
||||
[stale, stale, stale,];
|
||||
const __VLS_export = (await import('vue')).defineComponent({
|
||||
__typeProps: {},
|
||||
});
|
||||
export default {};
|
||||
@@ -0,0 +1,46 @@
|
||||
import { KsDataGrid } from './components';
|
||||
const __VLS_props = withDefaults(defineProps(), { loading: false, emptyMessage: '표시할 데이터가 없습니다.' });
|
||||
const __VLS_defaults = { loading: false, emptyMessage: '표시할 데이터가 없습니다.' };
|
||||
const __VLS_ctx = {
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
};
|
||||
let __VLS_components;
|
||||
let __VLS_intrinsics;
|
||||
let __VLS_directives;
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.section, __VLS_intrinsics.section)({
|
||||
'aria-label': "데이터 표",
|
||||
'aria-busy': (__VLS_ctx.loading),
|
||||
});
|
||||
if (__VLS_ctx.loading) {
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.p, __VLS_intrinsics.p)({});
|
||||
}
|
||||
else if (__VLS_ctx.rows.length === 0) {
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.p, __VLS_intrinsics.p)({});
|
||||
(__VLS_ctx.emptyMessage);
|
||||
}
|
||||
else {
|
||||
let __VLS_0;
|
||||
/** @ts-ignore @type { | typeof __VLS_components.KsDataGrid} */
|
||||
KsDataGrid;
|
||||
// @ts-ignore
|
||||
const __VLS_1 = __VLS_asFunctionalComponent1(__VLS_0, new __VLS_0({
|
||||
rows: (__VLS_ctx.rows),
|
||||
columns: (__VLS_ctx.columns),
|
||||
height: "30rem",
|
||||
}));
|
||||
const __VLS_2 = __VLS_1({
|
||||
rows: (__VLS_ctx.rows),
|
||||
columns: (__VLS_ctx.columns),
|
||||
height: "30rem",
|
||||
}, ...__VLS_functionalComponentArgsRest(__VLS_1));
|
||||
}
|
||||
// @ts-ignore
|
||||
[loading, loading, rows, rows, emptyMessage, columns,];
|
||||
const __VLS_export = (await import('vue')).defineComponent({
|
||||
__typeProps: {},
|
||||
props: {},
|
||||
});
|
||||
export default {};
|
||||
@@ -0,0 +1,38 @@
|
||||
const props = defineProps();
|
||||
const __VLS_ctx = {
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
};
|
||||
let __VLS_components;
|
||||
let __VLS_intrinsics;
|
||||
let __VLS_directives;
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.dl, __VLS_intrinsics.dl)({
|
||||
...{ class: "version-set" },
|
||||
'data-compact': (props.compact ? 'true' : 'false'),
|
||||
});
|
||||
/** @type {__VLS_StyleScopedClasses['version-set']} */ ;
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.dt, __VLS_intrinsics.dt)({});
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.dd, __VLS_intrinsics.dd)({});
|
||||
(props.value.datasetId);
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.dt, __VLS_intrinsics.dt)({});
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.dd, __VLS_intrinsics.dd)({});
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.code, __VLS_intrinsics.code)({});
|
||||
(props.value.dataHash);
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.dt, __VLS_intrinsics.dt)({});
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.dd, __VLS_intrinsics.dd)({});
|
||||
(props.value.modelVersion);
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.dt, __VLS_intrinsics.dt)({});
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.dd, __VLS_intrinsics.dd)({});
|
||||
(props.value.configVersion);
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.dt, __VLS_intrinsics.dt)({});
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.dd, __VLS_intrinsics.dd)({});
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.code, __VLS_intrinsics.code)({});
|
||||
(props.value.codeSha);
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.dt, __VLS_intrinsics.dt)({});
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.dd, __VLS_intrinsics.dd)({});
|
||||
(props.value.contractVersion);
|
||||
const __VLS_export = (await import('vue')).defineComponent({
|
||||
__typeProps: {},
|
||||
});
|
||||
export default {};
|
||||
@@ -0,0 +1,232 @@
|
||||
import KsButton from './components/KsButton.vue';
|
||||
import KsInlineMessage from './components/KsInlineMessage.vue';
|
||||
const props = defineProps();
|
||||
const emit = defineEmits();
|
||||
const __VLS_ctx = {
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
};
|
||||
let __VLS_components;
|
||||
let __VLS_intrinsics;
|
||||
let __VLS_directives;
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.section, __VLS_intrinsics.section)({
|
||||
'aria-busy': (props.loading || props.processing),
|
||||
});
|
||||
if (props.loading) {
|
||||
const __VLS_0 = KsInlineMessage;
|
||||
// @ts-ignore
|
||||
const __VLS_1 = __VLS_asFunctionalComponent1(__VLS_0, new __VLS_0({
|
||||
severity: "info",
|
||||
message: "불러오는 중입니다.",
|
||||
}));
|
||||
const __VLS_2 = __VLS_1({
|
||||
severity: "info",
|
||||
message: "불러오는 중입니다.",
|
||||
}, ...__VLS_functionalComponentArgsRest(__VLS_1));
|
||||
}
|
||||
else if (props.unauthorized) {
|
||||
const __VLS_5 = KsInlineMessage;
|
||||
// @ts-ignore
|
||||
const __VLS_6 = __VLS_asFunctionalComponent1(__VLS_5, new __VLS_5({
|
||||
severity: "warning",
|
||||
title: "로그인 필요",
|
||||
message: "로그인 후 다시 시도하세요.",
|
||||
}));
|
||||
const __VLS_7 = __VLS_6({
|
||||
severity: "warning",
|
||||
title: "로그인 필요",
|
||||
message: "로그인 후 다시 시도하세요.",
|
||||
}, ...__VLS_functionalComponentArgsRest(__VLS_6));
|
||||
}
|
||||
else if (props.forbidden) {
|
||||
const __VLS_10 = KsInlineMessage;
|
||||
// @ts-ignore
|
||||
const __VLS_11 = __VLS_asFunctionalComponent1(__VLS_10, new __VLS_10({
|
||||
severity: "danger",
|
||||
title: "권한 없음",
|
||||
message: "이 작업을 수행할 권한이 없습니다.",
|
||||
}));
|
||||
const __VLS_12 = __VLS_11({
|
||||
severity: "danger",
|
||||
title: "권한 없음",
|
||||
message: "이 작업을 수행할 권한이 없습니다.",
|
||||
}, ...__VLS_functionalComponentArgsRest(__VLS_11));
|
||||
}
|
||||
else if (props.conflict) {
|
||||
const __VLS_15 = KsInlineMessage;
|
||||
// @ts-ignore
|
||||
const __VLS_16 = __VLS_asFunctionalComponent1(__VLS_15, new __VLS_15({
|
||||
severity: "warning",
|
||||
title: "변경 충돌",
|
||||
message: "다른 사용자가 먼저 변경했습니다. 최신 버전을 확인하세요.",
|
||||
}));
|
||||
const __VLS_17 = __VLS_16({
|
||||
severity: "warning",
|
||||
title: "변경 충돌",
|
||||
message: "다른 사용자가 먼저 변경했습니다. 최신 버전을 확인하세요.",
|
||||
}, ...__VLS_functionalComponentArgsRest(__VLS_16));
|
||||
}
|
||||
else if (props.expired) {
|
||||
const __VLS_20 = KsInlineMessage;
|
||||
// @ts-ignore
|
||||
const __VLS_21 = __VLS_asFunctionalComponent1(__VLS_20, new __VLS_20({
|
||||
severity: "warning",
|
||||
title: "유효기간 만료",
|
||||
message: "만료된 증거 또는 제안은 실행·공개할 수 없습니다.",
|
||||
}));
|
||||
const __VLS_22 = __VLS_21({
|
||||
severity: "warning",
|
||||
title: "유효기간 만료",
|
||||
message: "만료된 증거 또는 제안은 실행·공개할 수 없습니다.",
|
||||
}, ...__VLS_functionalComponentArgsRest(__VLS_21));
|
||||
}
|
||||
else if (props.error) {
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.div, __VLS_intrinsics.div)({
|
||||
role: "alert",
|
||||
...{ class: "ks-state-error" },
|
||||
});
|
||||
/** @type {__VLS_StyleScopedClasses['ks-state-error']} */ ;
|
||||
const __VLS_25 = KsInlineMessage;
|
||||
// @ts-ignore
|
||||
const __VLS_26 = __VLS_asFunctionalComponent1(__VLS_25, new __VLS_25({
|
||||
severity: "danger",
|
||||
title: "요청 실패",
|
||||
message: (props.error.message),
|
||||
}));
|
||||
const __VLS_27 = __VLS_26({
|
||||
severity: "danger",
|
||||
title: "요청 실패",
|
||||
message: (props.error.message),
|
||||
}, ...__VLS_functionalComponentArgsRest(__VLS_26));
|
||||
const __VLS_30 = KsButton;
|
||||
// @ts-ignore
|
||||
const __VLS_31 = __VLS_asFunctionalComponent1(__VLS_30, new __VLS_30({
|
||||
...{ 'onClick': {} },
|
||||
label: "같은 요청 다시 시도",
|
||||
severity: "secondary",
|
||||
}));
|
||||
const __VLS_32 = __VLS_31({
|
||||
...{ 'onClick': {} },
|
||||
label: "같은 요청 다시 시도",
|
||||
severity: "secondary",
|
||||
}, ...__VLS_functionalComponentArgsRest(__VLS_31));
|
||||
let __VLS_35;
|
||||
const __VLS_36 = {
|
||||
/** @type {typeof __VLS_35.click} */
|
||||
onClick: (...[$event]) => {
|
||||
if (!!(props.loading))
|
||||
throw 0;
|
||||
if (!!(props.unauthorized))
|
||||
throw 0;
|
||||
if (!!(props.forbidden))
|
||||
throw 0;
|
||||
if (!!(props.conflict))
|
||||
throw 0;
|
||||
if (!!(props.expired))
|
||||
throw 0;
|
||||
if (!(props.error))
|
||||
throw 0;
|
||||
return (__VLS_ctx.emit('retry'));
|
||||
// @ts-ignore
|
||||
[emit,];
|
||||
},
|
||||
};
|
||||
var __VLS_33;
|
||||
var __VLS_34;
|
||||
if (__VLS_ctx.correlationId) {
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.small, __VLS_intrinsics.small)({});
|
||||
(__VLS_ctx.correlationId);
|
||||
}
|
||||
}
|
||||
else if (props.empty) {
|
||||
const __VLS_37 = KsInlineMessage;
|
||||
// @ts-ignore
|
||||
const __VLS_38 = __VLS_asFunctionalComponent1(__VLS_37, new __VLS_37({
|
||||
severity: "info",
|
||||
message: "표시할 데이터가 없습니다.",
|
||||
}));
|
||||
const __VLS_39 = __VLS_38({
|
||||
severity: "info",
|
||||
message: "표시할 데이터가 없습니다.",
|
||||
}, ...__VLS_functionalComponentArgsRest(__VLS_38));
|
||||
}
|
||||
else {
|
||||
if (props.partial) {
|
||||
const __VLS_42 = KsInlineMessage;
|
||||
// @ts-ignore
|
||||
const __VLS_43 = __VLS_asFunctionalComponent1(__VLS_42, new __VLS_42({
|
||||
severity: "warning",
|
||||
message: "일부 데이터만 표시하고 있습니다. 완전성 경고를 확인하세요.",
|
||||
}));
|
||||
const __VLS_44 = __VLS_43({
|
||||
severity: "warning",
|
||||
message: "일부 데이터만 표시하고 있습니다. 완전성 경고를 확인하세요.",
|
||||
}, ...__VLS_functionalComponentArgsRest(__VLS_43));
|
||||
}
|
||||
if (props.warning) {
|
||||
const __VLS_47 = KsInlineMessage;
|
||||
// @ts-ignore
|
||||
const __VLS_48 = __VLS_asFunctionalComponent1(__VLS_47, new __VLS_47({
|
||||
severity: "warning",
|
||||
message: (props.warning),
|
||||
}));
|
||||
const __VLS_49 = __VLS_48({
|
||||
severity: "warning",
|
||||
message: (props.warning),
|
||||
}, ...__VLS_functionalComponentArgsRest(__VLS_48));
|
||||
}
|
||||
if (props.readonly) {
|
||||
const __VLS_52 = KsInlineMessage;
|
||||
// @ts-ignore
|
||||
const __VLS_53 = __VLS_asFunctionalComponent1(__VLS_52, new __VLS_52({
|
||||
severity: "info",
|
||||
message: "읽기 전용 상태입니다.",
|
||||
}));
|
||||
const __VLS_54 = __VLS_53({
|
||||
severity: "info",
|
||||
message: "읽기 전용 상태입니다.",
|
||||
}, ...__VLS_functionalComponentArgsRest(__VLS_53));
|
||||
}
|
||||
if (props.dirty) {
|
||||
const __VLS_57 = KsInlineMessage;
|
||||
// @ts-ignore
|
||||
const __VLS_58 = __VLS_asFunctionalComponent1(__VLS_57, new __VLS_57({
|
||||
severity: "warning",
|
||||
message: "저장되지 않은 변경사항이 있습니다.",
|
||||
}));
|
||||
const __VLS_59 = __VLS_58({
|
||||
severity: "warning",
|
||||
message: "저장되지 않은 변경사항이 있습니다.",
|
||||
}, ...__VLS_functionalComponentArgsRest(__VLS_58));
|
||||
}
|
||||
if (props.processing) {
|
||||
const __VLS_62 = KsInlineMessage;
|
||||
// @ts-ignore
|
||||
const __VLS_63 = __VLS_asFunctionalComponent1(__VLS_62, new __VLS_62({
|
||||
severity: "info",
|
||||
message: "처리 중입니다. 중복 제출하지 마세요.",
|
||||
}));
|
||||
const __VLS_64 = __VLS_63({
|
||||
severity: "info",
|
||||
message: "처리 중입니다. 중복 제출하지 마세요.",
|
||||
}, ...__VLS_functionalComponentArgsRest(__VLS_63));
|
||||
}
|
||||
var __VLS_67 = {};
|
||||
}
|
||||
if (props.staleAt) {
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.small, __VLS_intrinsics.small)({});
|
||||
(props.staleAt);
|
||||
}
|
||||
// @ts-ignore
|
||||
var __VLS_68 = __VLS_67;
|
||||
// @ts-ignore
|
||||
[correlationId, correlationId,];
|
||||
const __VLS_base = (await import('vue')).defineComponent({
|
||||
__typeEmits: {},
|
||||
__typeProps: {},
|
||||
});
|
||||
const __VLS_export = {};
|
||||
export default {};
|
||||
@@ -0,0 +1,47 @@
|
||||
const props = defineProps();
|
||||
const emit = defineEmits();
|
||||
const __VLS_ctx = {
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
};
|
||||
let __VLS_components;
|
||||
let __VLS_intrinsics;
|
||||
let __VLS_directives;
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.dialog, __VLS_intrinsics.dialog)({
|
||||
open: (props.open),
|
||||
'aria-labelledby': "version-conflict-title",
|
||||
});
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.h2, __VLS_intrinsics.h2)({
|
||||
id: "version-conflict-title",
|
||||
});
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.p, __VLS_intrinsics.p)({});
|
||||
if (props.currentVersion) {
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.p, __VLS_intrinsics.p)({});
|
||||
(props.currentVersion);
|
||||
}
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.button, __VLS_intrinsics.button)({
|
||||
...{ onClick: (...[$event]) => {
|
||||
return (__VLS_ctx.emit('reload'));
|
||||
// @ts-ignore
|
||||
[emit,];
|
||||
} },
|
||||
type: "button",
|
||||
});
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.button, __VLS_intrinsics.button)({
|
||||
...{ onClick: (...[$event]) => {
|
||||
return (__VLS_ctx.emit('close'));
|
||||
// @ts-ignore
|
||||
[emit,];
|
||||
} },
|
||||
type: "button",
|
||||
});
|
||||
// @ts-ignore
|
||||
[];
|
||||
const __VLS_export = (await import('vue')).defineComponent({
|
||||
__typeEmits: {},
|
||||
__typeProps: {},
|
||||
});
|
||||
export default {};
|
||||
@@ -0,0 +1,29 @@
|
||||
const componentByCapability = {
|
||||
'button': 'Button', 'text-field': 'TextField', 'text-area': 'TextArea', 'select': 'Select',
|
||||
'multi-select': 'MultiSelect', 'checkbox': 'Checkbox', 'date-field': 'DateField',
|
||||
'number-field': 'NumberField', 'dialog': 'Dialog', 'status-tag': 'StatusTag',
|
||||
'inline-message': 'InlineMessage', 'paginator': 'Paginator', 'tabs': 'Tabs', 'data-grid': 'DataGrid'
|
||||
};
|
||||
export function evaluateUiAdapterCompatibility(adapter, requiredCapabilities, requireProductionEligible = false) {
|
||||
const issues = [];
|
||||
if (adapter.descriptor.contractVersion !== '4.0') {
|
||||
issues.push({ code: 'CONTRACT_VERSION', severity: 'ERROR', detail: `Expected 4.0, got ${adapter.descriptor.contractVersion}` });
|
||||
}
|
||||
for (const capability of requiredCapabilities) {
|
||||
if (!adapter.descriptor.capabilities.has(capability)) {
|
||||
issues.push({ code: 'MISSING_CAPABILITY', severity: 'ERROR', detail: capability });
|
||||
continue;
|
||||
}
|
||||
const component = adapter.components[componentByCapability[capability]];
|
||||
if (!component)
|
||||
issues.push({ code: 'MISSING_COMPONENT', severity: 'ERROR', detail: capability });
|
||||
}
|
||||
if (requireProductionEligible && !adapter.descriptor.productionEligible) {
|
||||
issues.push({ code: 'PRODUCTION_INELIGIBLE', severity: 'ERROR', detail: adapter.descriptor.id });
|
||||
}
|
||||
return { adapterId: adapter.descriptor.id, contractVersion: adapter.descriptor.contractVersion, compatible: !issues.some(x => x.severity === 'ERROR'), issues };
|
||||
}
|
||||
export function assertUiAdapterCompatibility(report) {
|
||||
if (!report.compatible)
|
||||
throw new Error(`UI adapter ${report.adapterId} is incompatible: ${report.issues.map(x => `${x.code}:${x.detail}`).join(', ')}`);
|
||||
}
|
||||
@@ -0,0 +1,22 @@
|
||||
export const requiredUiAdapterCapabilities = Object.freeze([
|
||||
'button', 'text-field', 'text-area', 'select', 'multi-select', 'checkbox', 'date-field',
|
||||
'number-field', 'dialog', 'status-tag', 'inline-message', 'paginator', 'tabs', 'data-grid'
|
||||
]);
|
||||
export function assertUiAdapterContract(adapter) {
|
||||
if (adapter.descriptor.contractVersion !== '4.0') {
|
||||
throw new Error(`Unsupported UI adapter contract: ${adapter.descriptor.contractVersion}`);
|
||||
}
|
||||
const missing = requiredUiAdapterCapabilities.filter(x => !adapter.descriptor.capabilities.has(x));
|
||||
if (missing.length > 0) {
|
||||
throw new Error(`UI adapter ${adapter.descriptor.id} is missing capabilities: ${missing.join(', ')}`);
|
||||
}
|
||||
const componentNames = [
|
||||
'Button', 'TextField', 'TextArea', 'Select', 'MultiSelect', 'Checkbox', 'DateField',
|
||||
'NumberField', 'Dialog', 'StatusTag', 'InlineMessage', 'Paginator', 'Tabs', 'DataGrid'
|
||||
];
|
||||
for (const name of componentNames) {
|
||||
if (!adapter.components[name])
|
||||
throw new Error(`UI adapter ${adapter.descriptor.id} has no component for ${name}`);
|
||||
}
|
||||
}
|
||||
export const uiAdapterKey = Symbol('KArtSellUiAdapterV4');
|
||||
@@ -0,0 +1,43 @@
|
||||
const __VLS_props = withDefaults(defineProps(), { severity: 'primary', type: 'button', disabled: false, loading: false });
|
||||
const emit = defineEmits();
|
||||
const __VLS_defaults = { severity: 'primary', type: 'button', disabled: false, loading: false };
|
||||
const __VLS_ctx = {
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
};
|
||||
let __VLS_components;
|
||||
let __VLS_intrinsics;
|
||||
let __VLS_directives;
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.button, __VLS_intrinsics.button)({
|
||||
...{ onClick: (...[$event]) => {
|
||||
return (__VLS_ctx.emit('activate', $event));
|
||||
// @ts-ignore
|
||||
[emit,];
|
||||
} },
|
||||
...{ class: "ks-native-button" },
|
||||
...{ class: (`is-${__VLS_ctx.severity}`) },
|
||||
type: (__VLS_ctx.type),
|
||||
disabled: (__VLS_ctx.disabled || __VLS_ctx.loading),
|
||||
});
|
||||
/** @type {__VLS_StyleScopedClasses['ks-native-button']} */ ;
|
||||
if (__VLS_ctx.loading) {
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.span, __VLS_intrinsics.span)({
|
||||
'aria-hidden': "true",
|
||||
});
|
||||
}
|
||||
var __VLS_0 = {};
|
||||
(__VLS_ctx.label);
|
||||
// @ts-ignore
|
||||
var __VLS_1 = __VLS_0;
|
||||
// @ts-ignore
|
||||
[severity, type, disabled, loading, loading, label,];
|
||||
const __VLS_base = (await import('vue')).defineComponent({
|
||||
__typeEmits: {},
|
||||
__typeProps: {},
|
||||
props: {},
|
||||
});
|
||||
const __VLS_export = {};
|
||||
export default {};
|
||||
@@ -0,0 +1,38 @@
|
||||
const __VLS_props = defineProps();
|
||||
const emit = defineEmits();
|
||||
const __VLS_ctx = {
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
};
|
||||
let __VLS_components;
|
||||
let __VLS_intrinsics;
|
||||
let __VLS_directives;
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.input)({
|
||||
...{ onChange: (...[$event]) => {
|
||||
return (__VLS_ctx.emit('update:modelValue', $event.target.checked));
|
||||
// @ts-ignore
|
||||
[emit,];
|
||||
} },
|
||||
...{ onBlur: (...[$event]) => {
|
||||
return (__VLS_ctx.emit('blur', $event));
|
||||
// @ts-ignore
|
||||
[emit,];
|
||||
} },
|
||||
id: (__VLS_ctx.inputId),
|
||||
...{ class: "ks-native-checkbox" },
|
||||
type: "checkbox",
|
||||
checked: (__VLS_ctx.modelValue),
|
||||
disabled: (__VLS_ctx.disabled),
|
||||
'aria-invalid': (__VLS_ctx.invalid || undefined),
|
||||
});
|
||||
/** @type {__VLS_StyleScopedClasses['ks-native-checkbox']} */ ;
|
||||
// @ts-ignore
|
||||
[inputId, modelValue, disabled, invalid,];
|
||||
const __VLS_export = (await import('vue')).defineComponent({
|
||||
__typeEmits: {},
|
||||
__typeProps: {},
|
||||
});
|
||||
export default {};
|
||||
@@ -0,0 +1,79 @@
|
||||
const __VLS_props = withDefaults(defineProps(), { loading: false, height: '32rem', rowSelection: 'single' });
|
||||
const emit = defineEmits();
|
||||
function value(row, field) { return typeof row === 'object' && row !== null ? row[field] : undefined; }
|
||||
const __VLS_defaults = { loading: false, height: '32rem', rowSelection: 'single' };
|
||||
const __VLS_ctx = {
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
};
|
||||
let __VLS_components;
|
||||
let __VLS_intrinsics;
|
||||
let __VLS_directives;
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.div, __VLS_intrinsics.div)({
|
||||
...{ class: "ks-native-grid" },
|
||||
...{ style: ({ maxHeight: __VLS_ctx.height }) },
|
||||
'aria-busy': (__VLS_ctx.loading),
|
||||
});
|
||||
/** @type {__VLS_StyleScopedClasses['ks-native-grid']} */ ;
|
||||
if (__VLS_ctx.loading) {
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.p, __VLS_intrinsics.p)({
|
||||
role: "status",
|
||||
});
|
||||
}
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.table, __VLS_intrinsics.table)({});
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.thead, __VLS_intrinsics.thead)({});
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.tr, __VLS_intrinsics.tr)({});
|
||||
for (const [column] of __VLS_vFor((__VLS_ctx.columns))) {
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.th, __VLS_intrinsics.th)({
|
||||
key: (column.field),
|
||||
scope: "col",
|
||||
...{ style: ({ width: column.width ? `${column.width}px` : undefined, minWidth: column.minWidth ? `${column.minWidth}px` : undefined }) },
|
||||
});
|
||||
(column.header);
|
||||
// @ts-ignore
|
||||
[height, loading, loading, columns,];
|
||||
}
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.tbody, __VLS_intrinsics.tbody)({});
|
||||
for (const [row, index] of __VLS_vFor((__VLS_ctx.rows))) {
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.tr, __VLS_intrinsics.tr)({
|
||||
...{ onClick: (...[$event]) => {
|
||||
return (__VLS_ctx.emit('row-selected', row));
|
||||
// @ts-ignore
|
||||
[rows, emit,];
|
||||
} },
|
||||
...{ onKeydown: (...[$event]) => {
|
||||
return (__VLS_ctx.emit('row-selected', row));
|
||||
// @ts-ignore
|
||||
[emit,];
|
||||
} },
|
||||
key: (index),
|
||||
tabindex: "0",
|
||||
});
|
||||
for (const [column] of __VLS_vFor((__VLS_ctx.columns))) {
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.td, __VLS_intrinsics.td)({
|
||||
key: (column.field),
|
||||
});
|
||||
(column.formatter ? column.formatter(__VLS_ctx.value(row, column.field), row) : __VLS_ctx.value(row, column.field));
|
||||
// @ts-ignore
|
||||
[columns, value, value,];
|
||||
}
|
||||
// @ts-ignore
|
||||
[];
|
||||
}
|
||||
if (!__VLS_ctx.loading && __VLS_ctx.rows.length === 0) {
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.tr, __VLS_intrinsics.tr)({});
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.td, __VLS_intrinsics.td)({
|
||||
colspan: (__VLS_ctx.columns.length),
|
||||
});
|
||||
}
|
||||
// @ts-ignore
|
||||
[loading, columns, rows,];
|
||||
const __VLS_export = (await import('vue')).defineComponent({
|
||||
__typeEmits: {},
|
||||
__typeProps: {},
|
||||
props: {},
|
||||
});
|
||||
export default {};
|
||||
@@ -0,0 +1,44 @@
|
||||
const __VLS_props = defineProps();
|
||||
const emit = defineEmits();
|
||||
function toDateValue(value) { if (!value)
|
||||
return ''; if (value instanceof Date)
|
||||
return value.toISOString().slice(0, 10); return value.slice(0, 10); }
|
||||
function boundary(value) { return value?.toISOString().slice(0, 10); }
|
||||
const __VLS_ctx = {
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
};
|
||||
let __VLS_components;
|
||||
let __VLS_intrinsics;
|
||||
let __VLS_directives;
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.input)({
|
||||
...{ onInput: (...[$event]) => {
|
||||
return (__VLS_ctx.emit('update:modelValue', $event.target.value || null));
|
||||
// @ts-ignore
|
||||
[emit,];
|
||||
} },
|
||||
...{ onBlur: (...[$event]) => {
|
||||
return (__VLS_ctx.emit('blur', $event));
|
||||
// @ts-ignore
|
||||
[emit,];
|
||||
} },
|
||||
id: (__VLS_ctx.inputId),
|
||||
...{ class: "ks-native-input" },
|
||||
type: "date",
|
||||
value: (__VLS_ctx.toDateValue(__VLS_ctx.modelValue)),
|
||||
disabled: (__VLS_ctx.disabled),
|
||||
'aria-invalid': (__VLS_ctx.invalid || undefined),
|
||||
min: (__VLS_ctx.boundary(__VLS_ctx.min)),
|
||||
max: (__VLS_ctx.boundary(__VLS_ctx.max)),
|
||||
});
|
||||
/** @type {__VLS_StyleScopedClasses['ks-native-input']} */ ;
|
||||
// @ts-ignore
|
||||
[inputId, toDateValue, modelValue, disabled, invalid, boundary, boundary, min, max,];
|
||||
const __VLS_export = (await import('vue')).defineComponent({
|
||||
__typeEmits: {},
|
||||
__typeProps: {},
|
||||
});
|
||||
export default {};
|
||||
@@ -0,0 +1,48 @@
|
||||
import { nextTick, ref, watch } from 'vue';
|
||||
const props = defineProps();
|
||||
const emit = defineEmits();
|
||||
const element = ref(null);
|
||||
watch(() => props.visible, async (visible) => { await nextTick(); const dialog = element.value; if (!dialog)
|
||||
return; if (visible && !dialog.open)
|
||||
props.modal === false ? dialog.show() : dialog.showModal(); if (!visible && dialog.open)
|
||||
dialog.close(); }, { immediate: true });
|
||||
function close() { emit('update:visible', false); }
|
||||
const __VLS_ctx = {
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
};
|
||||
let __VLS_components;
|
||||
let __VLS_intrinsics;
|
||||
let __VLS_directives;
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.dialog, __VLS_intrinsics.dialog)({
|
||||
...{ onClose: (__VLS_ctx.close) },
|
||||
...{ onCancel: (__VLS_ctx.close) },
|
||||
ref: "element",
|
||||
...{ class: "ks-native-dialog" },
|
||||
});
|
||||
/** @type {__VLS_StyleScopedClasses['ks-native-dialog']} */ ;
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.header, __VLS_intrinsics.header)({});
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.h2, __VLS_intrinsics.h2)({});
|
||||
(__VLS_ctx.title);
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.button, __VLS_intrinsics.button)({
|
||||
...{ onClick: (__VLS_ctx.close) },
|
||||
type: "button",
|
||||
'aria-label': "닫기",
|
||||
});
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.section, __VLS_intrinsics.section)({});
|
||||
var __VLS_0 = {};
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.footer, __VLS_intrinsics.footer)({});
|
||||
var __VLS_2 = {};
|
||||
// @ts-ignore
|
||||
var __VLS_1 = __VLS_0, __VLS_3 = __VLS_2;
|
||||
// @ts-ignore
|
||||
[close, close, close, title,];
|
||||
const __VLS_base = (await import('vue')).defineComponent({
|
||||
__typeEmits: {},
|
||||
__typeProps: {},
|
||||
});
|
||||
const __VLS_export = {};
|
||||
export default {};
|
||||
@@ -0,0 +1,46 @@
|
||||
const __VLS_props = withDefaults(defineProps(), { severity: 'info', dismissible: false });
|
||||
const emit = defineEmits();
|
||||
const __VLS_defaults = { severity: 'info', dismissible: false };
|
||||
const __VLS_ctx = {
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
};
|
||||
let __VLS_components;
|
||||
let __VLS_intrinsics;
|
||||
let __VLS_directives;
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.div, __VLS_intrinsics.div)({
|
||||
...{ class: "ks-inline-message" },
|
||||
'data-severity': (__VLS_ctx.severity),
|
||||
role: (__VLS_ctx.severity === 'danger' ? 'alert' : 'status'),
|
||||
});
|
||||
/** @type {__VLS_StyleScopedClasses['ks-inline-message']} */ ;
|
||||
if (__VLS_ctx.title) {
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.strong, __VLS_intrinsics.strong)({});
|
||||
(__VLS_ctx.title);
|
||||
}
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.span, __VLS_intrinsics.span)({});
|
||||
(__VLS_ctx.message);
|
||||
if (__VLS_ctx.dismissible) {
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.button, __VLS_intrinsics.button)({
|
||||
...{ onClick: (...[$event]) => {
|
||||
if (!(__VLS_ctx.dismissible))
|
||||
throw 0;
|
||||
return (__VLS_ctx.emit('dismiss'));
|
||||
// @ts-ignore
|
||||
[severity, severity, title, title, message, dismissible, emit,];
|
||||
} },
|
||||
type: "button",
|
||||
'aria-label': "메시지 닫기",
|
||||
});
|
||||
}
|
||||
// @ts-ignore
|
||||
[];
|
||||
const __VLS_export = (await import('vue')).defineComponent({
|
||||
__typeEmits: {},
|
||||
__typeProps: {},
|
||||
props: {},
|
||||
});
|
||||
export default {};
|
||||
@@ -0,0 +1,58 @@
|
||||
const props = withDefaults(defineProps(), { modelValue: () => [] });
|
||||
const emit = defineEmits();
|
||||
function update(event) {
|
||||
const selected = Array.from(event.target.selectedOptions).map(x => {
|
||||
const option = props.options[Number(x.value)];
|
||||
return option?.value ?? null;
|
||||
});
|
||||
emit('update:modelValue', selected);
|
||||
}
|
||||
const __VLS_defaults = { modelValue: () => [] };
|
||||
const __VLS_ctx = {
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
};
|
||||
let __VLS_components;
|
||||
let __VLS_intrinsics;
|
||||
let __VLS_directives;
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.label, __VLS_intrinsics.label)({
|
||||
...{ class: "ks-field" },
|
||||
});
|
||||
/** @type {__VLS_StyleScopedClasses['ks-field']} */ ;
|
||||
if (__VLS_ctx.label) {
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.span, __VLS_intrinsics.span)({});
|
||||
(__VLS_ctx.label);
|
||||
if (__VLS_ctx.required) {
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.b, __VLS_intrinsics.b)({
|
||||
'aria-hidden': "true",
|
||||
});
|
||||
}
|
||||
}
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.select, __VLS_intrinsics.select)({
|
||||
...{ onChange: (__VLS_ctx.update) },
|
||||
multiple: true,
|
||||
disabled: (__VLS_ctx.disabled),
|
||||
required: (__VLS_ctx.required),
|
||||
});
|
||||
for (const [option, index] of __VLS_vFor((__VLS_ctx.options))) {
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.option, __VLS_intrinsics.option)({
|
||||
key: (`${index}:${option.label}`),
|
||||
value: (index),
|
||||
disabled: (option.disabled),
|
||||
selected: (__VLS_ctx.modelValue.includes(option.value)),
|
||||
});
|
||||
(option.label);
|
||||
// @ts-ignore
|
||||
[label, label, required, required, update, disabled, options, modelValue,];
|
||||
}
|
||||
// @ts-ignore
|
||||
[];
|
||||
const __VLS_export = (await import('vue')).defineComponent({
|
||||
__typeEmits: {},
|
||||
__typeProps: {},
|
||||
props: {},
|
||||
});
|
||||
export default {};
|
||||
@@ -0,0 +1,43 @@
|
||||
const __VLS_props = defineProps();
|
||||
const emit = defineEmits();
|
||||
function parse(raw) { if (raw.trim() === '')
|
||||
return null; const value = Number(raw); return Number.isFinite(value) ? value : null; }
|
||||
const __VLS_ctx = {
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
};
|
||||
let __VLS_components;
|
||||
let __VLS_intrinsics;
|
||||
let __VLS_directives;
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.input)({
|
||||
...{ onInput: (...[$event]) => {
|
||||
return (__VLS_ctx.emit('update:modelValue', __VLS_ctx.parse($event.target.value)));
|
||||
// @ts-ignore
|
||||
[emit, parse,];
|
||||
} },
|
||||
...{ onBlur: (...[$event]) => {
|
||||
return (__VLS_ctx.emit('blur', $event));
|
||||
// @ts-ignore
|
||||
[emit,];
|
||||
} },
|
||||
id: (__VLS_ctx.inputId),
|
||||
...{ class: "ks-native-input" },
|
||||
type: "number",
|
||||
value: (__VLS_ctx.modelValue ?? ''),
|
||||
disabled: (__VLS_ctx.disabled),
|
||||
'aria-invalid': (__VLS_ctx.invalid || undefined),
|
||||
min: (__VLS_ctx.min),
|
||||
max: (__VLS_ctx.max),
|
||||
step: (__VLS_ctx.maxFractionDigits ? 1 / 10 ** __VLS_ctx.maxFractionDigits : 1),
|
||||
});
|
||||
/** @type {__VLS_StyleScopedClasses['ks-native-input']} */ ;
|
||||
// @ts-ignore
|
||||
[inputId, modelValue, disabled, invalid, min, max, maxFractionDigits, maxFractionDigits,];
|
||||
const __VLS_export = (await import('vue')).defineComponent({
|
||||
__typeEmits: {},
|
||||
__typeProps: {},
|
||||
});
|
||||
export default {};
|
||||
@@ -0,0 +1,66 @@
|
||||
const props = withDefaults(defineProps(), { pageSizes: () => [20, 50, 100], disabled: false });
|
||||
const emit = defineEmits();
|
||||
const pageCount = () => Math.max(1, Math.ceil(props.total / props.pageSize));
|
||||
function move(page) { emit('pageChange', { page: Math.min(Math.max(1, page), pageCount()), pageSize: props.pageSize }); }
|
||||
function size(event) { emit('pageChange', { page: 1, pageSize: Number(event.target.value) }); }
|
||||
const __VLS_defaults = { pageSizes: () => [20, 50, 100], disabled: false };
|
||||
const __VLS_ctx = {
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
};
|
||||
let __VLS_components;
|
||||
let __VLS_intrinsics;
|
||||
let __VLS_directives;
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.nav, __VLS_intrinsics.nav)({
|
||||
...{ class: "ks-paginator" },
|
||||
'aria-label': "목록 페이지",
|
||||
});
|
||||
/** @type {__VLS_StyleScopedClasses['ks-paginator']} */ ;
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.button, __VLS_intrinsics.button)({
|
||||
...{ onClick: (...[$event]) => {
|
||||
return (__VLS_ctx.move(__VLS_ctx.page - 1));
|
||||
// @ts-ignore
|
||||
[move, page,];
|
||||
} },
|
||||
type: "button",
|
||||
disabled: (__VLS_ctx.disabled || __VLS_ctx.page <= 1),
|
||||
});
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.span, __VLS_intrinsics.span)({});
|
||||
(__VLS_ctx.page);
|
||||
(__VLS_ctx.pageCount());
|
||||
(__VLS_ctx.total);
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.button, __VLS_intrinsics.button)({
|
||||
...{ onClick: (...[$event]) => {
|
||||
return (__VLS_ctx.move(__VLS_ctx.page + 1));
|
||||
// @ts-ignore
|
||||
[move, page, page, page, disabled, pageCount, total,];
|
||||
} },
|
||||
type: "button",
|
||||
disabled: (__VLS_ctx.disabled || __VLS_ctx.page >= __VLS_ctx.pageCount()),
|
||||
});
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.label, __VLS_intrinsics.label)({});
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.select, __VLS_intrinsics.select)({
|
||||
...{ onChange: (__VLS_ctx.size) },
|
||||
value: (__VLS_ctx.pageSize),
|
||||
disabled: (__VLS_ctx.disabled),
|
||||
});
|
||||
for (const [item] of __VLS_vFor((__VLS_ctx.pageSizes))) {
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.option, __VLS_intrinsics.option)({
|
||||
key: (item),
|
||||
value: (item),
|
||||
});
|
||||
(item);
|
||||
// @ts-ignore
|
||||
[page, disabled, disabled, pageCount, size, pageSize, pageSizes,];
|
||||
}
|
||||
// @ts-ignore
|
||||
[];
|
||||
const __VLS_export = (await import('vue')).defineComponent({
|
||||
__typeEmits: {},
|
||||
__typeProps: {},
|
||||
props: {},
|
||||
});
|
||||
export default {};
|
||||
@@ -0,0 +1,56 @@
|
||||
const props = defineProps();
|
||||
const emit = defineEmits();
|
||||
function encode(value) { return JSON.stringify(value); }
|
||||
function decode(raw) { const option = props.options.find(x => encode(x.value) === raw); return option?.value ?? null; }
|
||||
const __VLS_ctx = {
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
};
|
||||
let __VLS_components;
|
||||
let __VLS_intrinsics;
|
||||
let __VLS_directives;
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.select, __VLS_intrinsics.select)({
|
||||
...{ onChange: (...[$event]) => {
|
||||
return (__VLS_ctx.emit('update:modelValue', __VLS_ctx.decode($event.target.value)));
|
||||
// @ts-ignore
|
||||
[emit, decode,];
|
||||
} },
|
||||
...{ onBlur: (...[$event]) => {
|
||||
return (__VLS_ctx.emit('blur', $event));
|
||||
// @ts-ignore
|
||||
[emit,];
|
||||
} },
|
||||
id: (__VLS_ctx.inputId),
|
||||
...{ class: "ks-native-input" },
|
||||
value: (__VLS_ctx.encode(__VLS_ctx.modelValue)),
|
||||
disabled: (__VLS_ctx.disabled),
|
||||
'aria-invalid': (__VLS_ctx.invalid || undefined),
|
||||
});
|
||||
/** @type {__VLS_StyleScopedClasses['ks-native-input']} */ ;
|
||||
if (__VLS_ctx.placeholder) {
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.option, __VLS_intrinsics.option)({
|
||||
value: "",
|
||||
disabled: true,
|
||||
});
|
||||
(__VLS_ctx.placeholder);
|
||||
}
|
||||
for (const [option] of __VLS_vFor((__VLS_ctx.options))) {
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.option, __VLS_intrinsics.option)({
|
||||
key: (__VLS_ctx.encode(option.value)),
|
||||
value: (__VLS_ctx.encode(option.value)),
|
||||
disabled: (option.disabled),
|
||||
});
|
||||
(option.label);
|
||||
// @ts-ignore
|
||||
[inputId, encode, encode, encode, modelValue, disabled, invalid, placeholder, placeholder, options,];
|
||||
}
|
||||
// @ts-ignore
|
||||
[];
|
||||
const __VLS_export = (await import('vue')).defineComponent({
|
||||
__typeEmits: {},
|
||||
__typeProps: {},
|
||||
});
|
||||
export default {};
|
||||
@@ -0,0 +1,23 @@
|
||||
const __VLS_props = withDefaults(defineProps(), { severity: 'info' });
|
||||
const __VLS_defaults = { severity: 'info' };
|
||||
const __VLS_ctx = {
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
};
|
||||
let __VLS_components;
|
||||
let __VLS_intrinsics;
|
||||
let __VLS_directives;
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.span, __VLS_intrinsics.span)({
|
||||
...{ class: "ks-native-tag" },
|
||||
...{ class: (`is-${__VLS_ctx.severity}`) },
|
||||
});
|
||||
/** @type {__VLS_StyleScopedClasses['ks-native-tag']} */ ;
|
||||
(__VLS_ctx.value);
|
||||
// @ts-ignore
|
||||
[severity, value,];
|
||||
const __VLS_export = (await import('vue')).defineComponent({
|
||||
__typeProps: {},
|
||||
props: {},
|
||||
});
|
||||
export default {};
|
||||
@@ -0,0 +1,58 @@
|
||||
const __VLS_props = withDefaults(defineProps(), { ariaLabel: '탭' });
|
||||
const emit = defineEmits();
|
||||
const __VLS_defaults = { ariaLabel: '탭' };
|
||||
const __VLS_ctx = {
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
};
|
||||
let __VLS_components;
|
||||
let __VLS_intrinsics;
|
||||
let __VLS_directives;
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.div, __VLS_intrinsics.div)({});
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.div, __VLS_intrinsics.div)({
|
||||
...{ class: "ks-tabs" },
|
||||
role: "tablist",
|
||||
'aria-label': (__VLS_ctx.ariaLabel),
|
||||
});
|
||||
/** @type {__VLS_StyleScopedClasses['ks-tabs']} */ ;
|
||||
for (const [item] of __VLS_vFor((__VLS_ctx.items))) {
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.button, __VLS_intrinsics.button)({
|
||||
...{ onClick: (...[$event]) => {
|
||||
return (__VLS_ctx.emit('update:modelValue', item.id));
|
||||
// @ts-ignore
|
||||
[ariaLabel, items, emit,];
|
||||
} },
|
||||
key: (item.id),
|
||||
type: "button",
|
||||
role: "tab",
|
||||
'aria-selected': (__VLS_ctx.modelValue === item.id),
|
||||
disabled: (item.disabled),
|
||||
});
|
||||
(item.label);
|
||||
if (item.badge) {
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.small, __VLS_intrinsics.small)({});
|
||||
(item.badge);
|
||||
}
|
||||
// @ts-ignore
|
||||
[modelValue,];
|
||||
}
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.div, __VLS_intrinsics.div)({
|
||||
role: "tabpanel",
|
||||
});
|
||||
var __VLS_0 = {
|
||||
activeId: (__VLS_ctx.modelValue),
|
||||
};
|
||||
// @ts-ignore
|
||||
var __VLS_1 = __VLS_0;
|
||||
// @ts-ignore
|
||||
[modelValue,];
|
||||
const __VLS_base = (await import('vue')).defineComponent({
|
||||
__typeEmits: {},
|
||||
__typeProps: {},
|
||||
props: {},
|
||||
});
|
||||
const __VLS_export = {};
|
||||
export default {};
|
||||
@@ -0,0 +1,39 @@
|
||||
const __VLS_props = defineProps();
|
||||
const emit = defineEmits();
|
||||
const __VLS_ctx = {
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
};
|
||||
let __VLS_components;
|
||||
let __VLS_intrinsics;
|
||||
let __VLS_directives;
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.textarea)({
|
||||
...{ onInput: (...[$event]) => {
|
||||
return (__VLS_ctx.emit('update:modelValue', $event.target.value));
|
||||
// @ts-ignore
|
||||
[emit,];
|
||||
} },
|
||||
...{ onBlur: (...[$event]) => {
|
||||
return (__VLS_ctx.emit('blur', $event));
|
||||
// @ts-ignore
|
||||
[emit,];
|
||||
} },
|
||||
id: (__VLS_ctx.inputId),
|
||||
...{ class: "ks-native-input" },
|
||||
value: (__VLS_ctx.modelValue),
|
||||
disabled: (__VLS_ctx.disabled),
|
||||
'aria-invalid': (__VLS_ctx.invalid || undefined),
|
||||
rows: (__VLS_ctx.rows ?? 4),
|
||||
placeholder: (__VLS_ctx.placeholder),
|
||||
});
|
||||
/** @type {__VLS_StyleScopedClasses['ks-native-input']} */ ;
|
||||
// @ts-ignore
|
||||
[inputId, modelValue, disabled, invalid, rows, placeholder,];
|
||||
const __VLS_export = (await import('vue')).defineComponent({
|
||||
__typeEmits: {},
|
||||
__typeProps: {},
|
||||
});
|
||||
export default {};
|
||||
@@ -0,0 +1,39 @@
|
||||
const __VLS_props = defineProps();
|
||||
const emit = defineEmits();
|
||||
const __VLS_ctx = {
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
};
|
||||
let __VLS_components;
|
||||
let __VLS_intrinsics;
|
||||
let __VLS_directives;
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.input)({
|
||||
...{ onInput: (...[$event]) => {
|
||||
return (__VLS_ctx.emit('update:modelValue', $event.target.value));
|
||||
// @ts-ignore
|
||||
[emit,];
|
||||
} },
|
||||
...{ onBlur: (...[$event]) => {
|
||||
return (__VLS_ctx.emit('blur', $event));
|
||||
// @ts-ignore
|
||||
[emit,];
|
||||
} },
|
||||
id: (__VLS_ctx.inputId),
|
||||
...{ class: "ks-native-input" },
|
||||
type: "text",
|
||||
value: (__VLS_ctx.modelValue),
|
||||
disabled: (__VLS_ctx.disabled),
|
||||
'aria-invalid': (__VLS_ctx.invalid || undefined),
|
||||
placeholder: (__VLS_ctx.placeholder),
|
||||
});
|
||||
/** @type {__VLS_StyleScopedClasses['ks-native-input']} */ ;
|
||||
// @ts-ignore
|
||||
[inputId, modelValue, disabled, invalid, placeholder,];
|
||||
const __VLS_export = (await import('vue')).defineComponent({
|
||||
__typeEmits: {},
|
||||
__typeProps: {},
|
||||
});
|
||||
export default {};
|
||||
@@ -0,0 +1,22 @@
|
||||
import Button from './NativeButtonAdapter.vue';
|
||||
import TextField from './NativeTextFieldAdapter.vue';
|
||||
import TextArea from './NativeTextAreaAdapter.vue';
|
||||
import Select from './NativeSelectAdapter.vue';
|
||||
import MultiSelect from './NativeMultiSelectAdapter.vue';
|
||||
import Checkbox from './NativeCheckboxAdapter.vue';
|
||||
import DateField from './NativeDateFieldAdapter.vue';
|
||||
import NumberField from './NativeNumberFieldAdapter.vue';
|
||||
import Dialog from './NativeDialogAdapter.vue';
|
||||
import StatusTag from './NativeStatusTagAdapter.vue';
|
||||
import InlineMessage from './NativeInlineMessageAdapter.vue';
|
||||
import Paginator from './NativePaginatorAdapter.vue';
|
||||
import Tabs from './NativeTabsAdapter.vue';
|
||||
import DataGrid from './NativeDataGridAdapter.vue';
|
||||
const capabilities = new Set([
|
||||
'button', 'text-field', 'text-area', 'select', 'multi-select', 'checkbox', 'date-field', 'number-field',
|
||||
'dialog', 'status-tag', 'inline-message', 'paginator', 'tabs', 'data-grid'
|
||||
]);
|
||||
export const nativeUiAdapter = Object.freeze({
|
||||
descriptor: Object.freeze({ id: 'native-accessible', version: '2.0.0', contractVersion: '4.0', vendor: 'HTML platform primitives', capabilities, productionEligible: false, accessibilityBaseline: 'WCAG_2_2_AA_TARGET' }),
|
||||
components: Object.freeze({ Button, TextField, TextArea, Select, MultiSelect, Checkbox, DateField, NumberField, Dialog, StatusTag, InlineMessage, Paginator, Tabs, DataGrid })
|
||||
});
|
||||
@@ -0,0 +1,7 @@
|
||||
import { installUiAdapter } from '../useUiAdapter';
|
||||
import { nativeUiAdapter } from './index';
|
||||
import './native.css';
|
||||
export const nativeUiProvider = {
|
||||
id: 'native-accessible',
|
||||
install(app) { installUiAdapter(app, nativeUiAdapter); }
|
||||
};
|
||||
@@ -0,0 +1,82 @@
|
||||
import { computed } from 'vue';
|
||||
import { AgGridVue } from 'ag-grid-vue3';
|
||||
import { AllCommunityModule, ModuleRegistry, themeQuartz } from 'ag-grid-community';
|
||||
ModuleRegistry.registerModules([AllCommunityModule]);
|
||||
const props = withDefaults(defineProps(), { loading: false, height: '32rem', rowSelection: 'single' });
|
||||
const emit = defineEmits();
|
||||
const columnDefs = computed(() => props.columns.map(column => ({
|
||||
field: column.field,
|
||||
headerName: column.header,
|
||||
width: column.width,
|
||||
minWidth: column.minWidth ?? 120,
|
||||
sortable: column.sortable ?? true,
|
||||
filter: column.filterable ?? true,
|
||||
valueFormatter: column.formatter
|
||||
? params => column.formatter?.(params.value, params.data) ?? ''
|
||||
: undefined
|
||||
})));
|
||||
const rowSelectionOptions = computed(() => {
|
||||
if (props.rowSelection === 'none')
|
||||
return undefined;
|
||||
return props.rowSelection === 'multiple'
|
||||
? { mode: 'multiRow' }
|
||||
: { mode: 'singleRow' };
|
||||
});
|
||||
function onRowClicked(event) {
|
||||
if (event.data)
|
||||
emit('rowSelected', event.data);
|
||||
}
|
||||
const __VLS_defaults = { loading: false, height: '32rem', rowSelection: 'single' };
|
||||
const __VLS_ctx = {
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
};
|
||||
let __VLS_components;
|
||||
let __VLS_intrinsics;
|
||||
let __VLS_directives;
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.div, __VLS_intrinsics.div)({
|
||||
...{ class: "ks-grid" },
|
||||
...{ style: ({ height: __VLS_ctx.height }) },
|
||||
'aria-busy': (__VLS_ctx.loading),
|
||||
});
|
||||
/** @type {__VLS_StyleScopedClasses['ks-grid']} */ ;
|
||||
let __VLS_0;
|
||||
/** @ts-ignore @type { | typeof __VLS_components.AgGridVue} */
|
||||
AgGridVue;
|
||||
// @ts-ignore
|
||||
const __VLS_1 = __VLS_asFunctionalComponent1(__VLS_0, new __VLS_0({
|
||||
...{ 'onRowClicked': {} },
|
||||
...{ style: {} },
|
||||
theme: (__VLS_ctx.themeQuartz),
|
||||
rowData: (__VLS_ctx.rows),
|
||||
columnDefs: (__VLS_ctx.columnDefs),
|
||||
rowSelection: (__VLS_ctx.rowSelectionOptions),
|
||||
loading: (__VLS_ctx.loading),
|
||||
}));
|
||||
const __VLS_2 = __VLS_1({
|
||||
...{ 'onRowClicked': {} },
|
||||
...{ style: {} },
|
||||
theme: (__VLS_ctx.themeQuartz),
|
||||
rowData: (__VLS_ctx.rows),
|
||||
columnDefs: (__VLS_ctx.columnDefs),
|
||||
rowSelection: (__VLS_ctx.rowSelectionOptions),
|
||||
loading: (__VLS_ctx.loading),
|
||||
}, ...__VLS_functionalComponentArgsRest(__VLS_1));
|
||||
let __VLS_5;
|
||||
const __VLS_6 = {
|
||||
/** @type {typeof __VLS_5.rowClicked} */
|
||||
onRowClicked: (__VLS_ctx.onRowClicked),
|
||||
};
|
||||
var __VLS_3;
|
||||
var __VLS_4;
|
||||
// @ts-ignore
|
||||
[height, loading, loading, themeQuartz, rows, columnDefs, rowSelectionOptions, onRowClicked,];
|
||||
const __VLS_export = (await import('vue')).defineComponent({
|
||||
__typeEmits: {},
|
||||
__typeProps: {},
|
||||
props: {},
|
||||
});
|
||||
export default {};
|
||||
@@ -0,0 +1,66 @@
|
||||
import Button from 'primevue/button';
|
||||
const __VLS_props = withDefaults(defineProps(), { severity: 'primary', type: 'button', disabled: false, loading: false });
|
||||
const __VLS_emit = defineEmits();
|
||||
const __VLS_defaults = { severity: 'primary', type: 'button', disabled: false, loading: false };
|
||||
const __VLS_ctx = {
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
};
|
||||
let __VLS_components;
|
||||
let __VLS_intrinsics;
|
||||
let __VLS_directives;
|
||||
/** @type {__VLS_StyleScopedClasses['ks-button']} */ ;
|
||||
/** @type {__VLS_StyleScopedClasses['ks-button']} */ ;
|
||||
let __VLS_0;
|
||||
/** @ts-ignore @type { | typeof __VLS_components.Button | typeof __VLS_components.Button} */
|
||||
Button;
|
||||
// @ts-ignore
|
||||
const __VLS_1 = __VLS_asFunctionalComponent1(__VLS_0, new __VLS_0({
|
||||
...{ 'onClick': {} },
|
||||
...{ class: "ks-button" },
|
||||
label: (__VLS_ctx.label),
|
||||
severity: (__VLS_ctx.severity),
|
||||
type: (__VLS_ctx.type),
|
||||
disabled: (__VLS_ctx.disabled),
|
||||
loading: (__VLS_ctx.loading),
|
||||
}));
|
||||
const __VLS_2 = __VLS_1({
|
||||
...{ 'onClick': {} },
|
||||
...{ class: "ks-button" },
|
||||
label: (__VLS_ctx.label),
|
||||
severity: (__VLS_ctx.severity),
|
||||
type: (__VLS_ctx.type),
|
||||
disabled: (__VLS_ctx.disabled),
|
||||
loading: (__VLS_ctx.loading),
|
||||
}, ...__VLS_functionalComponentArgsRest(__VLS_1));
|
||||
let __VLS_5;
|
||||
const __VLS_6 = {
|
||||
/** @type {typeof __VLS_5.click} */
|
||||
onClick: (...[$event]) => {
|
||||
return (__VLS_ctx.$emit('activate', $event));
|
||||
// @ts-ignore
|
||||
[label, severity, type, disabled, loading, $emit,];
|
||||
},
|
||||
};
|
||||
var __VLS_7;
|
||||
/** @type {__VLS_StyleScopedClasses['ks-button']} */ ;
|
||||
const { default: __VLS_8 } = __VLS_3.slots;
|
||||
var __VLS_9 = {};
|
||||
// @ts-ignore
|
||||
[];
|
||||
var __VLS_3;
|
||||
var __VLS_4;
|
||||
// @ts-ignore
|
||||
var __VLS_10 = __VLS_9;
|
||||
// @ts-ignore
|
||||
[];
|
||||
const __VLS_base = (await import('vue')).defineComponent({
|
||||
__typeEmits: {},
|
||||
__typeProps: {},
|
||||
props: {},
|
||||
});
|
||||
const __VLS_export = {};
|
||||
export default {};
|
||||
@@ -0,0 +1,53 @@
|
||||
import Checkbox from 'primevue/checkbox';
|
||||
const __VLS_props = defineProps();
|
||||
const __VLS_emit = defineEmits();
|
||||
const __VLS_ctx = {
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
};
|
||||
let __VLS_components;
|
||||
let __VLS_intrinsics;
|
||||
let __VLS_directives;
|
||||
let __VLS_0;
|
||||
/** @ts-ignore @type { | typeof __VLS_components.Checkbox} */
|
||||
Checkbox;
|
||||
// @ts-ignore
|
||||
const __VLS_1 = __VLS_asFunctionalComponent1(__VLS_0, new __VLS_0({
|
||||
...{ 'onUpdate:modelValue': {} },
|
||||
...{ class: "ks-checkbox" },
|
||||
inputId: (__VLS_ctx.inputId),
|
||||
modelValue: (__VLS_ctx.modelValue),
|
||||
binary: true,
|
||||
disabled: (__VLS_ctx.disabled),
|
||||
}));
|
||||
const __VLS_2 = __VLS_1({
|
||||
...{ 'onUpdate:modelValue': {} },
|
||||
...{ class: "ks-checkbox" },
|
||||
inputId: (__VLS_ctx.inputId),
|
||||
modelValue: (__VLS_ctx.modelValue),
|
||||
binary: true,
|
||||
disabled: (__VLS_ctx.disabled),
|
||||
}, ...__VLS_functionalComponentArgsRest(__VLS_1));
|
||||
let __VLS_5;
|
||||
const __VLS_6 = {
|
||||
/** @type {typeof __VLS_5.'update:modelValue'} */
|
||||
'onUpdate:modelValue': (...[$event]) => {
|
||||
return (__VLS_ctx.$emit('update:modelValue', Boolean($event)));
|
||||
// @ts-ignore
|
||||
[inputId, modelValue, disabled, $emit,];
|
||||
},
|
||||
};
|
||||
var __VLS_7;
|
||||
/** @type {__VLS_StyleScopedClasses['ks-checkbox']} */ ;
|
||||
var __VLS_3;
|
||||
var __VLS_4;
|
||||
// @ts-ignore
|
||||
[];
|
||||
const __VLS_export = (await import('vue')).defineComponent({
|
||||
__typeEmits: {},
|
||||
__typeProps: {},
|
||||
});
|
||||
export default {};
|
||||
@@ -1,19 +1,30 @@
|
||||
<script setup lang="ts">
|
||||
import DatePicker from 'primevue/datepicker'
|
||||
defineProps<{ modelValue: string | Date | null; inputId?: string; disabled?: boolean; invalid?: boolean; min?: Date; max?: Date }>()
|
||||
const emit = defineEmits<{ 'update:modelValue': [value: string | Date | null]; blur: [event: FocusEvent] }>()
|
||||
import { computed } from 'vue'
|
||||
const props = defineProps<{ modelValue: string | Date | null; inputId?: string; disabled?: boolean; invalid?: boolean; min?: Date; max?: Date }>()
|
||||
const emit = defineEmits<{ 'update:modelValue': [value: string | Date | null]; blur: [event: Event] }>()
|
||||
const dateValue = computed(() => {
|
||||
if (props.modelValue instanceof Date) return props.modelValue
|
||||
if (typeof props.modelValue === 'string') return new Date(props.modelValue)
|
||||
return null
|
||||
})
|
||||
const handleDateChange = (value: Date | Date[] | (Date | null)[] | null | undefined) => {
|
||||
if (value instanceof Date) emit('update:modelValue', value)
|
||||
else if (value === null || value === undefined) emit('update:modelValue', null)
|
||||
else emit('update:modelValue', value[0] ?? null)
|
||||
}
|
||||
</script>
|
||||
<template>
|
||||
<DatePicker
|
||||
:input-id="inputId"
|
||||
:model-value="modelValue"
|
||||
:model-value="dateValue"
|
||||
:disabled="disabled"
|
||||
:invalid="invalid"
|
||||
:min-date="min"
|
||||
:max-date="max"
|
||||
date-format="yy-mm-dd"
|
||||
show-icon
|
||||
@update:model-value="emit('update:modelValue', $event)"
|
||||
@blur="emit('blur', $event)"
|
||||
@update:model-value="handleDateChange"
|
||||
@blur="emit('blur', $event as unknown as Event)"
|
||||
/>
|
||||
</template>
|
||||
|
||||
@@ -0,0 +1,80 @@
|
||||
import DatePicker from 'primevue/datepicker';
|
||||
import { computed } from 'vue';
|
||||
const props = defineProps();
|
||||
const emit = defineEmits();
|
||||
const dateValue = computed(() => {
|
||||
if (props.modelValue instanceof Date)
|
||||
return props.modelValue;
|
||||
if (typeof props.modelValue === 'string')
|
||||
return new Date(props.modelValue);
|
||||
return null;
|
||||
});
|
||||
const handleDateChange = (value) => {
|
||||
if (value instanceof Date)
|
||||
emit('update:modelValue', value);
|
||||
else if (value === null || value === undefined)
|
||||
emit('update:modelValue', null);
|
||||
else
|
||||
emit('update:modelValue', value[0] ?? null);
|
||||
};
|
||||
const __VLS_ctx = {
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
};
|
||||
let __VLS_components;
|
||||
let __VLS_intrinsics;
|
||||
let __VLS_directives;
|
||||
let __VLS_0;
|
||||
/** @ts-ignore @type { | typeof __VLS_components.DatePicker} */
|
||||
DatePicker;
|
||||
// @ts-ignore
|
||||
const __VLS_1 = __VLS_asFunctionalComponent1(__VLS_0, new __VLS_0({
|
||||
...{ 'onUpdate:modelValue': {} },
|
||||
...{ 'onBlur': {} },
|
||||
inputId: (__VLS_ctx.inputId),
|
||||
modelValue: (__VLS_ctx.dateValue),
|
||||
disabled: (__VLS_ctx.disabled),
|
||||
invalid: (__VLS_ctx.invalid),
|
||||
minDate: (__VLS_ctx.min),
|
||||
maxDate: (__VLS_ctx.max),
|
||||
dateFormat: "yy-mm-dd",
|
||||
showIcon: true,
|
||||
}));
|
||||
const __VLS_2 = __VLS_1({
|
||||
...{ 'onUpdate:modelValue': {} },
|
||||
...{ 'onBlur': {} },
|
||||
inputId: (__VLS_ctx.inputId),
|
||||
modelValue: (__VLS_ctx.dateValue),
|
||||
disabled: (__VLS_ctx.disabled),
|
||||
invalid: (__VLS_ctx.invalid),
|
||||
minDate: (__VLS_ctx.min),
|
||||
maxDate: (__VLS_ctx.max),
|
||||
dateFormat: "yy-mm-dd",
|
||||
showIcon: true,
|
||||
}, ...__VLS_functionalComponentArgsRest(__VLS_1));
|
||||
let __VLS_5;
|
||||
const __VLS_6 = {
|
||||
/** @type {typeof __VLS_5.'update:modelValue'} */
|
||||
'onUpdate:modelValue': (__VLS_ctx.handleDateChange),
|
||||
};
|
||||
const __VLS_7 = {
|
||||
/** @type {typeof __VLS_5.blur} */
|
||||
onBlur: (...[$event]) => {
|
||||
return (__VLS_ctx.emit('blur', $event));
|
||||
// @ts-ignore
|
||||
[inputId, dateValue, disabled, invalid, min, max, handleDateChange, emit,];
|
||||
},
|
||||
};
|
||||
var __VLS_8;
|
||||
var __VLS_3;
|
||||
var __VLS_4;
|
||||
// @ts-ignore
|
||||
[];
|
||||
const __VLS_export = (await import('vue')).defineComponent({
|
||||
__typeEmits: {},
|
||||
__typeProps: {},
|
||||
});
|
||||
export default {};
|
||||
@@ -0,0 +1,66 @@
|
||||
import Dialog from 'primevue/dialog';
|
||||
const __VLS_props = defineProps();
|
||||
const __VLS_emit = defineEmits();
|
||||
const __VLS_ctx = {
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
};
|
||||
let __VLS_components;
|
||||
let __VLS_intrinsics;
|
||||
let __VLS_directives;
|
||||
let __VLS_0;
|
||||
/** @ts-ignore @type { | typeof __VLS_components.Dialog | typeof __VLS_components.Dialog} */
|
||||
Dialog;
|
||||
// @ts-ignore
|
||||
const __VLS_1 = __VLS_asFunctionalComponent1(__VLS_0, new __VLS_0({
|
||||
...{ 'onUpdate:visible': {} },
|
||||
...{ class: "ks-dialog" },
|
||||
visible: (__VLS_ctx.visible),
|
||||
header: (__VLS_ctx.title),
|
||||
modal: (__VLS_ctx.modal ?? true),
|
||||
closable: (__VLS_ctx.closable ?? true),
|
||||
}));
|
||||
const __VLS_2 = __VLS_1({
|
||||
...{ 'onUpdate:visible': {} },
|
||||
...{ class: "ks-dialog" },
|
||||
visible: (__VLS_ctx.visible),
|
||||
header: (__VLS_ctx.title),
|
||||
modal: (__VLS_ctx.modal ?? true),
|
||||
closable: (__VLS_ctx.closable ?? true),
|
||||
}, ...__VLS_functionalComponentArgsRest(__VLS_1));
|
||||
let __VLS_5;
|
||||
const __VLS_6 = {
|
||||
/** @type {typeof __VLS_5.'update:visible'} */
|
||||
'onUpdate:visible': (...[$event]) => {
|
||||
return (__VLS_ctx.$emit('update:visible', $event));
|
||||
// @ts-ignore
|
||||
[visible, title, modal, closable, $emit,];
|
||||
},
|
||||
};
|
||||
var __VLS_7;
|
||||
/** @type {__VLS_StyleScopedClasses['ks-dialog']} */ ;
|
||||
const { default: __VLS_8 } = __VLS_3.slots;
|
||||
var __VLS_9 = {};
|
||||
{
|
||||
const { footer: __VLS_11 } = __VLS_3.slots;
|
||||
var __VLS_12 = {};
|
||||
// @ts-ignore
|
||||
[];
|
||||
}
|
||||
// @ts-ignore
|
||||
[];
|
||||
var __VLS_3;
|
||||
var __VLS_4;
|
||||
// @ts-ignore
|
||||
var __VLS_10 = __VLS_9, __VLS_13 = __VLS_12;
|
||||
// @ts-ignore
|
||||
[];
|
||||
const __VLS_base = (await import('vue')).defineComponent({
|
||||
__typeEmits: {},
|
||||
__typeProps: {},
|
||||
});
|
||||
const __VLS_export = {};
|
||||
export default {};
|
||||
@@ -0,0 +1,57 @@
|
||||
import Message from 'primevue/message';
|
||||
const __VLS_props = withDefaults(defineProps(), { severity: 'info', dismissible: false });
|
||||
const emit = defineEmits();
|
||||
const map = { primary: 'info', secondary: 'secondary', success: 'success', info: 'info', warning: 'warn', danger: 'error' };
|
||||
const __VLS_defaults = { severity: 'info', dismissible: false };
|
||||
const __VLS_ctx = {
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
};
|
||||
let __VLS_components;
|
||||
let __VLS_intrinsics;
|
||||
let __VLS_directives;
|
||||
let __VLS_0;
|
||||
/** @ts-ignore @type { | typeof __VLS_components.Message | typeof __VLS_components.Message} */
|
||||
Message;
|
||||
// @ts-ignore
|
||||
const __VLS_1 = __VLS_asFunctionalComponent1(__VLS_0, new __VLS_0({
|
||||
...{ 'onClose': {} },
|
||||
severity: (__VLS_ctx.map[__VLS_ctx.severity]),
|
||||
closable: (__VLS_ctx.dismissible),
|
||||
}));
|
||||
const __VLS_2 = __VLS_1({
|
||||
...{ 'onClose': {} },
|
||||
severity: (__VLS_ctx.map[__VLS_ctx.severity]),
|
||||
closable: (__VLS_ctx.dismissible),
|
||||
}, ...__VLS_functionalComponentArgsRest(__VLS_1));
|
||||
let __VLS_5;
|
||||
const __VLS_6 = {
|
||||
/** @type {typeof __VLS_5.close} */
|
||||
onClose: (...[$event]) => {
|
||||
return (__VLS_ctx.emit('dismiss'));
|
||||
// @ts-ignore
|
||||
[map, severity, dismissible, emit,];
|
||||
},
|
||||
};
|
||||
var __VLS_7;
|
||||
const { default: __VLS_8 } = __VLS_3.slots;
|
||||
if (__VLS_ctx.title) {
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.strong, __VLS_intrinsics.strong)({});
|
||||
(__VLS_ctx.title);
|
||||
}
|
||||
(__VLS_ctx.message);
|
||||
// @ts-ignore
|
||||
[title, title, message,];
|
||||
var __VLS_3;
|
||||
var __VLS_4;
|
||||
// @ts-ignore
|
||||
[];
|
||||
const __VLS_export = (await import('vue')).defineComponent({
|
||||
__typeEmits: {},
|
||||
__typeProps: {},
|
||||
props: {},
|
||||
});
|
||||
export default {};
|
||||
@@ -0,0 +1,68 @@
|
||||
import MultiSelect from 'primevue/multiselect';
|
||||
const __VLS_props = withDefaults(defineProps(), { modelValue: () => [] });
|
||||
const emit = defineEmits();
|
||||
const __VLS_defaults = { modelValue: () => [] };
|
||||
const __VLS_ctx = {
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
};
|
||||
let __VLS_components;
|
||||
let __VLS_intrinsics;
|
||||
let __VLS_directives;
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.label, __VLS_intrinsics.label)({
|
||||
...{ class: "ks-field" },
|
||||
});
|
||||
/** @type {__VLS_StyleScopedClasses['ks-field']} */ ;
|
||||
if (__VLS_ctx.label) {
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.span, __VLS_intrinsics.span)({});
|
||||
(__VLS_ctx.label);
|
||||
if (__VLS_ctx.required) {
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.b, __VLS_intrinsics.b)({
|
||||
'aria-hidden': "true",
|
||||
});
|
||||
}
|
||||
}
|
||||
let __VLS_0;
|
||||
/** @ts-ignore @type { | typeof __VLS_components.MultiSelect} */
|
||||
MultiSelect;
|
||||
// @ts-ignore
|
||||
const __VLS_1 = __VLS_asFunctionalComponent1(__VLS_0, new __VLS_0({
|
||||
...{ 'onUpdate:modelValue': {} },
|
||||
modelValue: (__VLS_ctx.modelValue),
|
||||
options: (__VLS_ctx.options),
|
||||
optionLabel: "label",
|
||||
optionValue: "value",
|
||||
optionDisabled: "disabled",
|
||||
disabled: (__VLS_ctx.disabled),
|
||||
}));
|
||||
const __VLS_2 = __VLS_1({
|
||||
...{ 'onUpdate:modelValue': {} },
|
||||
modelValue: (__VLS_ctx.modelValue),
|
||||
options: (__VLS_ctx.options),
|
||||
optionLabel: "label",
|
||||
optionValue: "value",
|
||||
optionDisabled: "disabled",
|
||||
disabled: (__VLS_ctx.disabled),
|
||||
}, ...__VLS_functionalComponentArgsRest(__VLS_1));
|
||||
let __VLS_5;
|
||||
const __VLS_6 = {
|
||||
/** @type {typeof __VLS_5.'update:modelValue'} */
|
||||
'onUpdate:modelValue': (...[$event]) => {
|
||||
return (__VLS_ctx.emit('update:modelValue', $event));
|
||||
// @ts-ignore
|
||||
[label, label, required, modelValue, options, disabled, emit,];
|
||||
},
|
||||
};
|
||||
var __VLS_3;
|
||||
var __VLS_4;
|
||||
// @ts-ignore
|
||||
[];
|
||||
const __VLS_export = (await import('vue')).defineComponent({
|
||||
__typeEmits: {},
|
||||
__typeProps: {},
|
||||
props: {},
|
||||
});
|
||||
export default {};
|
||||
@@ -1,7 +1,7 @@
|
||||
<script setup lang="ts">
|
||||
import InputNumber from 'primevue/inputnumber'
|
||||
defineProps<{ modelValue: number | null; inputId?: string; disabled?: boolean; invalid?: boolean; min?: number; max?: number; minFractionDigits?: number; maxFractionDigits?: number }>()
|
||||
const emit = defineEmits<{ 'update:modelValue': [value: number | null]; blur: [event: FocusEvent] }>()
|
||||
const emit = defineEmits<{ 'update:modelValue': [value: number | null]; blur: [event: Event] }>()
|
||||
</script>
|
||||
<template>
|
||||
<InputNumber
|
||||
@@ -14,6 +14,6 @@ const emit = defineEmits<{ 'update:modelValue': [value: number | null]; blur: [e
|
||||
:min-fraction-digits="minFractionDigits"
|
||||
:max-fraction-digits="maxFractionDigits"
|
||||
@update:model-value="emit('update:modelValue', $event)"
|
||||
@blur="emit('blur', $event)"
|
||||
@blur="emit('blur', $event as unknown as Event)"
|
||||
/>
|
||||
</template>
|
||||
|
||||
@@ -0,0 +1,68 @@
|
||||
import InputNumber from 'primevue/inputnumber';
|
||||
const __VLS_props = defineProps();
|
||||
const emit = defineEmits();
|
||||
const __VLS_ctx = {
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
};
|
||||
let __VLS_components;
|
||||
let __VLS_intrinsics;
|
||||
let __VLS_directives;
|
||||
let __VLS_0;
|
||||
/** @ts-ignore @type { | typeof __VLS_components.InputNumber} */
|
||||
InputNumber;
|
||||
// @ts-ignore
|
||||
const __VLS_1 = __VLS_asFunctionalComponent1(__VLS_0, new __VLS_0({
|
||||
...{ 'onUpdate:modelValue': {} },
|
||||
...{ 'onBlur': {} },
|
||||
inputId: (__VLS_ctx.inputId),
|
||||
modelValue: (__VLS_ctx.modelValue),
|
||||
disabled: (__VLS_ctx.disabled),
|
||||
invalid: (__VLS_ctx.invalid),
|
||||
min: (__VLS_ctx.min),
|
||||
max: (__VLS_ctx.max),
|
||||
minFractionDigits: (__VLS_ctx.minFractionDigits),
|
||||
maxFractionDigits: (__VLS_ctx.maxFractionDigits),
|
||||
}));
|
||||
const __VLS_2 = __VLS_1({
|
||||
...{ 'onUpdate:modelValue': {} },
|
||||
...{ 'onBlur': {} },
|
||||
inputId: (__VLS_ctx.inputId),
|
||||
modelValue: (__VLS_ctx.modelValue),
|
||||
disabled: (__VLS_ctx.disabled),
|
||||
invalid: (__VLS_ctx.invalid),
|
||||
min: (__VLS_ctx.min),
|
||||
max: (__VLS_ctx.max),
|
||||
minFractionDigits: (__VLS_ctx.minFractionDigits),
|
||||
maxFractionDigits: (__VLS_ctx.maxFractionDigits),
|
||||
}, ...__VLS_functionalComponentArgsRest(__VLS_1));
|
||||
let __VLS_5;
|
||||
const __VLS_6 = {
|
||||
/** @type {typeof __VLS_5.'update:modelValue'} */
|
||||
'onUpdate:modelValue': (...[$event]) => {
|
||||
return (__VLS_ctx.emit('update:modelValue', $event));
|
||||
// @ts-ignore
|
||||
[inputId, modelValue, disabled, invalid, min, max, minFractionDigits, maxFractionDigits, emit,];
|
||||
},
|
||||
};
|
||||
const __VLS_7 = {
|
||||
/** @type {typeof __VLS_5.blur} */
|
||||
onBlur: (...[$event]) => {
|
||||
return (__VLS_ctx.emit('blur', $event));
|
||||
// @ts-ignore
|
||||
[emit,];
|
||||
},
|
||||
};
|
||||
var __VLS_8;
|
||||
var __VLS_3;
|
||||
var __VLS_4;
|
||||
// @ts-ignore
|
||||
[];
|
||||
const __VLS_export = (await import('vue')).defineComponent({
|
||||
__typeEmits: {},
|
||||
__typeProps: {},
|
||||
});
|
||||
export default {};
|
||||
@@ -0,0 +1,54 @@
|
||||
import Paginator from 'primevue/paginator';
|
||||
const __VLS_props = withDefaults(defineProps(), { pageSizes: () => [20, 50, 100], disabled: false });
|
||||
const emit = defineEmits();
|
||||
const __VLS_defaults = { pageSizes: () => [20, 50, 100], disabled: false };
|
||||
const __VLS_ctx = {
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
};
|
||||
let __VLS_components;
|
||||
let __VLS_intrinsics;
|
||||
let __VLS_directives;
|
||||
let __VLS_0;
|
||||
/** @ts-ignore @type { | typeof __VLS_components.Paginator} */
|
||||
Paginator;
|
||||
// @ts-ignore
|
||||
const __VLS_1 = __VLS_asFunctionalComponent1(__VLS_0, new __VLS_0({
|
||||
...{ 'onPage': {} },
|
||||
first: ((__VLS_ctx.page - 1) * __VLS_ctx.pageSize),
|
||||
rows: (__VLS_ctx.pageSize),
|
||||
totalRecords: (__VLS_ctx.total),
|
||||
rowsPerPageOptions: (__VLS_ctx.pageSizes),
|
||||
disabled: (__VLS_ctx.disabled),
|
||||
}));
|
||||
const __VLS_2 = __VLS_1({
|
||||
...{ 'onPage': {} },
|
||||
first: ((__VLS_ctx.page - 1) * __VLS_ctx.pageSize),
|
||||
rows: (__VLS_ctx.pageSize),
|
||||
totalRecords: (__VLS_ctx.total),
|
||||
rowsPerPageOptions: (__VLS_ctx.pageSizes),
|
||||
disabled: (__VLS_ctx.disabled),
|
||||
}, ...__VLS_functionalComponentArgsRest(__VLS_1));
|
||||
let __VLS_5;
|
||||
const __VLS_6 = {
|
||||
/** @type {typeof __VLS_5.page} */
|
||||
onPage: (...[$event]) => {
|
||||
return (__VLS_ctx.emit('pageChange', { page: $event.page + 1, pageSize: $event.rows }));
|
||||
// @ts-ignore
|
||||
[page, pageSize, pageSize, total, pageSizes, disabled, emit,];
|
||||
},
|
||||
};
|
||||
var __VLS_7;
|
||||
var __VLS_3;
|
||||
var __VLS_4;
|
||||
// @ts-ignore
|
||||
[];
|
||||
const __VLS_export = (await import('vue')).defineComponent({
|
||||
__typeEmits: {},
|
||||
__typeProps: {},
|
||||
props: {},
|
||||
});
|
||||
export default {};
|
||||
@@ -3,7 +3,7 @@ import Select from 'primevue/select'
|
||||
import type { UiSelectOption } from '../contracts'
|
||||
|
||||
defineProps<{ modelValue: unknown; inputId?: string; options: UiSelectOption[]; disabled?: boolean; invalid?: boolean; placeholder?: string }>()
|
||||
defineEmits<{ 'update:modelValue': [value: unknown]; blur: [event: FocusEvent] }>()
|
||||
defineEmits<{ 'update:modelValue': [value: unknown]; blur: [event: Event] }>()
|
||||
</script>
|
||||
|
||||
<template>
|
||||
@@ -19,7 +19,7 @@ defineEmits<{ 'update:modelValue': [value: unknown]; blur: [event: FocusEvent] }
|
||||
:invalid="invalid"
|
||||
:placeholder="placeholder"
|
||||
@update:model-value="$emit('update:modelValue', $event)"
|
||||
@blur="$emit('blur', $event)"
|
||||
@blur="$emit('blur', $event as unknown as Event)"
|
||||
/>
|
||||
</template>
|
||||
|
||||
|
||||
@@ -0,0 +1,73 @@
|
||||
import Select from 'primevue/select';
|
||||
const __VLS_props = defineProps();
|
||||
const __VLS_emit = defineEmits();
|
||||
const __VLS_ctx = {
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
};
|
||||
let __VLS_components;
|
||||
let __VLS_intrinsics;
|
||||
let __VLS_directives;
|
||||
let __VLS_0;
|
||||
/** @ts-ignore @type { | typeof __VLS_components.Select} */
|
||||
Select;
|
||||
// @ts-ignore
|
||||
const __VLS_1 = __VLS_asFunctionalComponent1(__VLS_0, new __VLS_0({
|
||||
...{ 'onUpdate:modelValue': {} },
|
||||
...{ 'onBlur': {} },
|
||||
...{ class: "ks-select" },
|
||||
inputId: (__VLS_ctx.inputId),
|
||||
modelValue: (__VLS_ctx.modelValue),
|
||||
options: (__VLS_ctx.options),
|
||||
optionLabel: "label",
|
||||
optionValue: "value",
|
||||
optionDisabled: "disabled",
|
||||
disabled: (__VLS_ctx.disabled),
|
||||
invalid: (__VLS_ctx.invalid),
|
||||
placeholder: (__VLS_ctx.placeholder),
|
||||
}));
|
||||
const __VLS_2 = __VLS_1({
|
||||
...{ 'onUpdate:modelValue': {} },
|
||||
...{ 'onBlur': {} },
|
||||
...{ class: "ks-select" },
|
||||
inputId: (__VLS_ctx.inputId),
|
||||
modelValue: (__VLS_ctx.modelValue),
|
||||
options: (__VLS_ctx.options),
|
||||
optionLabel: "label",
|
||||
optionValue: "value",
|
||||
optionDisabled: "disabled",
|
||||
disabled: (__VLS_ctx.disabled),
|
||||
invalid: (__VLS_ctx.invalid),
|
||||
placeholder: (__VLS_ctx.placeholder),
|
||||
}, ...__VLS_functionalComponentArgsRest(__VLS_1));
|
||||
let __VLS_5;
|
||||
const __VLS_6 = {
|
||||
/** @type {typeof __VLS_5.'update:modelValue'} */
|
||||
'onUpdate:modelValue': (...[$event]) => {
|
||||
return (__VLS_ctx.$emit('update:modelValue', $event));
|
||||
// @ts-ignore
|
||||
[inputId, modelValue, options, disabled, invalid, placeholder, $emit,];
|
||||
},
|
||||
};
|
||||
const __VLS_7 = {
|
||||
/** @type {typeof __VLS_5.blur} */
|
||||
onBlur: (...[$event]) => {
|
||||
return (__VLS_ctx.$emit('blur', $event));
|
||||
// @ts-ignore
|
||||
[$emit,];
|
||||
},
|
||||
};
|
||||
var __VLS_8;
|
||||
/** @type {__VLS_StyleScopedClasses['ks-select']} */ ;
|
||||
var __VLS_3;
|
||||
var __VLS_4;
|
||||
// @ts-ignore
|
||||
[];
|
||||
const __VLS_export = (await import('vue')).defineComponent({
|
||||
__typeEmits: {},
|
||||
__typeProps: {},
|
||||
});
|
||||
export default {};
|
||||
@@ -0,0 +1,43 @@
|
||||
import Tag from 'primevue/tag';
|
||||
const __VLS_props = defineProps();
|
||||
const __VLS_ctx = {
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
};
|
||||
let __VLS_components;
|
||||
let __VLS_intrinsics;
|
||||
let __VLS_directives;
|
||||
let __VLS_0;
|
||||
/** @ts-ignore @type { | typeof __VLS_components.Tag | typeof __VLS_components.Tag} */
|
||||
Tag;
|
||||
// @ts-ignore
|
||||
const __VLS_1 = __VLS_asFunctionalComponent1(__VLS_0, new __VLS_0({
|
||||
...{ class: "ks-status-tag" },
|
||||
severity: (__VLS_ctx.severity ?? 'info'),
|
||||
}));
|
||||
const __VLS_2 = __VLS_1({
|
||||
...{ class: "ks-status-tag" },
|
||||
severity: (__VLS_ctx.severity ?? 'info'),
|
||||
}, ...__VLS_functionalComponentArgsRest(__VLS_1));
|
||||
var __VLS_5;
|
||||
/** @type {__VLS_StyleScopedClasses['ks-status-tag']} */ ;
|
||||
const { default: __VLS_6 } = __VLS_3.slots;
|
||||
if (__VLS_ctx.iconLabel) {
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.span, __VLS_intrinsics.span)({
|
||||
'aria-hidden': "true",
|
||||
});
|
||||
(__VLS_ctx.iconLabel);
|
||||
}
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.span, __VLS_intrinsics.span)({});
|
||||
(__VLS_ctx.value);
|
||||
// @ts-ignore
|
||||
[severity, iconLabel, iconLabel, value,];
|
||||
var __VLS_3;
|
||||
// @ts-ignore
|
||||
[];
|
||||
const __VLS_export = (await import('vue')).defineComponent({
|
||||
__typeProps: {},
|
||||
});
|
||||
export default {};
|
||||
@@ -0,0 +1,58 @@
|
||||
const __VLS_props = withDefaults(defineProps(), { ariaLabel: '탭' });
|
||||
const emit = defineEmits();
|
||||
const __VLS_defaults = { ariaLabel: '탭' };
|
||||
const __VLS_ctx = {
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
};
|
||||
let __VLS_components;
|
||||
let __VLS_intrinsics;
|
||||
let __VLS_directives;
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.div, __VLS_intrinsics.div)({});
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.div, __VLS_intrinsics.div)({
|
||||
...{ class: "ks-tabs" },
|
||||
role: "tablist",
|
||||
'aria-label': (__VLS_ctx.ariaLabel),
|
||||
});
|
||||
/** @type {__VLS_StyleScopedClasses['ks-tabs']} */ ;
|
||||
for (const [item] of __VLS_vFor((__VLS_ctx.items))) {
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.button, __VLS_intrinsics.button)({
|
||||
...{ onClick: (...[$event]) => {
|
||||
return (__VLS_ctx.emit('update:modelValue', item.id));
|
||||
// @ts-ignore
|
||||
[ariaLabel, items, emit,];
|
||||
} },
|
||||
key: (item.id),
|
||||
type: "button",
|
||||
role: "tab",
|
||||
'aria-selected': (__VLS_ctx.modelValue === item.id),
|
||||
disabled: (item.disabled),
|
||||
});
|
||||
(item.label);
|
||||
if (item.badge) {
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.small, __VLS_intrinsics.small)({});
|
||||
(item.badge);
|
||||
}
|
||||
// @ts-ignore
|
||||
[modelValue,];
|
||||
}
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.div, __VLS_intrinsics.div)({
|
||||
role: "tabpanel",
|
||||
});
|
||||
var __VLS_0 = {
|
||||
activeId: (__VLS_ctx.modelValue),
|
||||
};
|
||||
// @ts-ignore
|
||||
var __VLS_1 = __VLS_0;
|
||||
// @ts-ignore
|
||||
[modelValue,];
|
||||
const __VLS_base = (await import('vue')).defineComponent({
|
||||
__typeEmits: {},
|
||||
__typeProps: {},
|
||||
props: {},
|
||||
});
|
||||
const __VLS_export = {};
|
||||
export default {};
|
||||
@@ -0,0 +1,67 @@
|
||||
import Textarea from 'primevue/textarea';
|
||||
const __VLS_props = defineProps();
|
||||
const __VLS_emit = defineEmits();
|
||||
const __VLS_ctx = {
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
};
|
||||
let __VLS_components;
|
||||
let __VLS_intrinsics;
|
||||
let __VLS_directives;
|
||||
let __VLS_0;
|
||||
/** @ts-ignore @type { | typeof __VLS_components.Textarea} */
|
||||
Textarea;
|
||||
// @ts-ignore
|
||||
const __VLS_1 = __VLS_asFunctionalComponent1(__VLS_0, new __VLS_0({
|
||||
...{ 'onUpdate:modelValue': {} },
|
||||
...{ 'onBlur': {} },
|
||||
...{ class: "ks-textarea" },
|
||||
id: (__VLS_ctx.inputId),
|
||||
modelValue: (__VLS_ctx.modelValue),
|
||||
disabled: (__VLS_ctx.disabled),
|
||||
invalid: (__VLS_ctx.invalid),
|
||||
rows: (__VLS_ctx.rows ?? 4),
|
||||
placeholder: (__VLS_ctx.placeholder),
|
||||
}));
|
||||
const __VLS_2 = __VLS_1({
|
||||
...{ 'onUpdate:modelValue': {} },
|
||||
...{ 'onBlur': {} },
|
||||
...{ class: "ks-textarea" },
|
||||
id: (__VLS_ctx.inputId),
|
||||
modelValue: (__VLS_ctx.modelValue),
|
||||
disabled: (__VLS_ctx.disabled),
|
||||
invalid: (__VLS_ctx.invalid),
|
||||
rows: (__VLS_ctx.rows ?? 4),
|
||||
placeholder: (__VLS_ctx.placeholder),
|
||||
}, ...__VLS_functionalComponentArgsRest(__VLS_1));
|
||||
let __VLS_5;
|
||||
const __VLS_6 = {
|
||||
/** @type {typeof __VLS_5.'update:modelValue'} */
|
||||
'onUpdate:modelValue': (...[$event]) => {
|
||||
return (__VLS_ctx.$emit('update:modelValue', String($event ?? '')));
|
||||
// @ts-ignore
|
||||
[inputId, modelValue, disabled, invalid, rows, placeholder, $emit,];
|
||||
},
|
||||
};
|
||||
const __VLS_7 = {
|
||||
/** @type {typeof __VLS_5.blur} */
|
||||
onBlur: (...[$event]) => {
|
||||
return (__VLS_ctx.$emit('blur', $event));
|
||||
// @ts-ignore
|
||||
[$emit,];
|
||||
},
|
||||
};
|
||||
var __VLS_8;
|
||||
/** @type {__VLS_StyleScopedClasses['ks-textarea']} */ ;
|
||||
var __VLS_3;
|
||||
var __VLS_4;
|
||||
// @ts-ignore
|
||||
[];
|
||||
const __VLS_export = (await import('vue')).defineComponent({
|
||||
__typeEmits: {},
|
||||
__typeProps: {},
|
||||
});
|
||||
export default {};
|
||||
@@ -0,0 +1,66 @@
|
||||
import InputText from 'primevue/inputtext';
|
||||
const __VLS_props = defineProps();
|
||||
const __VLS_emit = defineEmits();
|
||||
const __VLS_ctx = {
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
};
|
||||
let __VLS_components;
|
||||
let __VLS_intrinsics;
|
||||
let __VLS_directives;
|
||||
/** @type {__VLS_StyleScopedClasses['ks-input']} */ ;
|
||||
let __VLS_0;
|
||||
/** @ts-ignore @type { | typeof __VLS_components.InputText} */
|
||||
InputText;
|
||||
// @ts-ignore
|
||||
const __VLS_1 = __VLS_asFunctionalComponent1(__VLS_0, new __VLS_0({
|
||||
...{ 'onUpdate:modelValue': {} },
|
||||
...{ 'onBlur': {} },
|
||||
...{ class: "ks-input" },
|
||||
id: (__VLS_ctx.inputId),
|
||||
modelValue: (__VLS_ctx.modelValue),
|
||||
disabled: (__VLS_ctx.disabled),
|
||||
invalid: (__VLS_ctx.invalid),
|
||||
placeholder: (__VLS_ctx.placeholder),
|
||||
}));
|
||||
const __VLS_2 = __VLS_1({
|
||||
...{ 'onUpdate:modelValue': {} },
|
||||
...{ 'onBlur': {} },
|
||||
...{ class: "ks-input" },
|
||||
id: (__VLS_ctx.inputId),
|
||||
modelValue: (__VLS_ctx.modelValue),
|
||||
disabled: (__VLS_ctx.disabled),
|
||||
invalid: (__VLS_ctx.invalid),
|
||||
placeholder: (__VLS_ctx.placeholder),
|
||||
}, ...__VLS_functionalComponentArgsRest(__VLS_1));
|
||||
let __VLS_5;
|
||||
const __VLS_6 = {
|
||||
/** @type {typeof __VLS_5.'update:modelValue'} */
|
||||
'onUpdate:modelValue': (...[$event]) => {
|
||||
return (__VLS_ctx.$emit('update:modelValue', String($event ?? '')));
|
||||
// @ts-ignore
|
||||
[inputId, modelValue, disabled, invalid, placeholder, $emit,];
|
||||
},
|
||||
};
|
||||
const __VLS_7 = {
|
||||
/** @type {typeof __VLS_5.blur} */
|
||||
onBlur: (...[$event]) => {
|
||||
return (__VLS_ctx.$emit('blur', $event));
|
||||
// @ts-ignore
|
||||
[$emit,];
|
||||
},
|
||||
};
|
||||
var __VLS_8;
|
||||
/** @type {__VLS_StyleScopedClasses['ks-input']} */ ;
|
||||
var __VLS_3;
|
||||
var __VLS_4;
|
||||
// @ts-ignore
|
||||
[];
|
||||
const __VLS_export = (await import('vue')).defineComponent({
|
||||
__typeEmits: {},
|
||||
__typeProps: {},
|
||||
});
|
||||
export default {};
|
||||
@@ -0,0 +1,22 @@
|
||||
import Button from './PrimeButtonAdapter.vue';
|
||||
import TextField from './PrimeTextFieldAdapter.vue';
|
||||
import TextArea from './PrimeTextAreaAdapter.vue';
|
||||
import Select from './PrimeSelectAdapter.vue';
|
||||
import MultiSelect from './PrimeMultiSelectAdapter.vue';
|
||||
import Checkbox from './PrimeCheckboxAdapter.vue';
|
||||
import DateField from './PrimeDateFieldAdapter.vue';
|
||||
import NumberField from './PrimeNumberFieldAdapter.vue';
|
||||
import Dialog from './PrimeDialogAdapter.vue';
|
||||
import StatusTag from './PrimeStatusTagAdapter.vue';
|
||||
import InlineMessage from './PrimeInlineMessageAdapter.vue';
|
||||
import Paginator from './PrimePaginatorAdapter.vue';
|
||||
import Tabs from './PrimeTabsAdapter.vue';
|
||||
import DataGrid from './AgGridAdapter.vue';
|
||||
const capabilities = new Set([
|
||||
'button', 'text-field', 'text-area', 'select', 'multi-select', 'checkbox', 'date-field', 'number-field',
|
||||
'dialog', 'status-tag', 'inline-message', 'paginator', 'tabs', 'data-grid'
|
||||
]);
|
||||
export const primeVueUiAdapter = Object.freeze({
|
||||
descriptor: Object.freeze({ id: 'primevue-aggrid', version: '4.x+34.x', contractVersion: '4.0', vendor: 'PrimeVue + AG Grid Community', capabilities, productionEligible: true, accessibilityBaseline: 'WCAG_2_2_AA_TARGET' }),
|
||||
components: Object.freeze({ Button, TextField, TextArea, Select, MultiSelect, Checkbox, DateField, NumberField, Dialog, StatusTag, InlineMessage, Paginator, Tabs, DataGrid })
|
||||
});
|
||||
@@ -0,0 +1,14 @@
|
||||
import PrimeVue from 'primevue/config';
|
||||
import { installUiAdapter } from '../useUiAdapter';
|
||||
import { primeVueUiAdapter } from './index';
|
||||
import './adapter.css';
|
||||
export const primeVueUiProvider = {
|
||||
id: 'primevue-aggrid',
|
||||
install(app) {
|
||||
app.use(PrimeVue, { unstyled: true });
|
||||
installUiAdapter(app, primeVueUiAdapter);
|
||||
}
|
||||
};
|
||||
export function installPrimeVueAdapter(app) {
|
||||
primeVueUiProvider.install(app);
|
||||
}
|
||||
@@ -0,0 +1,12 @@
|
||||
import { describe, expect, it } from 'vitest';
|
||||
import { assertUiAdapterContract, requiredUiAdapterCapabilities } from '../contracts';
|
||||
import { nativeUiAdapter } from '../native';
|
||||
import { primeVueUiAdapter } from '../primevue';
|
||||
describe.each([nativeUiAdapter, primeVueUiAdapter])('UI adapter $descriptor.id', adapter => {
|
||||
it('implements the complete v4 normalized contract', () => {
|
||||
expect(() => assertUiAdapterContract(adapter)).not.toThrow();
|
||||
expect(adapter.descriptor.contractVersion).toBe('4.0');
|
||||
expect(adapter.descriptor.capabilities.size).toBe(requiredUiAdapterCapabilities.length);
|
||||
expect(adapter.descriptor.accessibilityBaseline).toBe('WCAG_2_2_AA_TARGET');
|
||||
});
|
||||
});
|
||||
@@ -0,0 +1,13 @@
|
||||
import { inject } from 'vue';
|
||||
import { assertUiAdapterContract, uiAdapterKey } from './contracts';
|
||||
export function installUiAdapter(app, adapter) {
|
||||
assertUiAdapterContract(adapter);
|
||||
app.provide(uiAdapterKey, adapter);
|
||||
}
|
||||
export function useUiAdapter() {
|
||||
const adapter = inject(uiAdapterKey);
|
||||
if (!adapter) {
|
||||
throw new Error('UI adapter is not installed. Install a validated provider during app bootstrap.');
|
||||
}
|
||||
return adapter;
|
||||
}
|
||||
@@ -0,0 +1,51 @@
|
||||
import { computed, useId } from 'vue';
|
||||
const props = defineProps();
|
||||
const generatedId = useId();
|
||||
const resolvedId = computed(() => props.inputId ?? `ks-field-${generatedId}`);
|
||||
const messageId = computed(() => props.error || props.help ? `${resolvedId.value}-message` : undefined);
|
||||
const __VLS_ctx = {
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
};
|
||||
let __VLS_components;
|
||||
let __VLS_intrinsics;
|
||||
let __VLS_directives;
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.div, __VLS_intrinsics.div)({
|
||||
...{ class: "ks-field-shell" },
|
||||
'data-invalid': (Boolean(__VLS_ctx.error) || undefined),
|
||||
});
|
||||
/** @type {__VLS_StyleScopedClasses['ks-field-shell']} */ ;
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.label, __VLS_intrinsics.label)({
|
||||
for: (__VLS_ctx.resolvedId),
|
||||
});
|
||||
(__VLS_ctx.label);
|
||||
if (__VLS_ctx.required) {
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.span, __VLS_intrinsics.span)({
|
||||
'aria-hidden': "true",
|
||||
});
|
||||
}
|
||||
var __VLS_0 = {
|
||||
inputId: (__VLS_ctx.resolvedId),
|
||||
describedBy: (__VLS_ctx.messageId),
|
||||
invalid: (Boolean(__VLS_ctx.error)),
|
||||
};
|
||||
if (__VLS_ctx.error || __VLS_ctx.help) {
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.small, __VLS_intrinsics.small)({
|
||||
id: (__VLS_ctx.messageId),
|
||||
...{ class: ({ 'ks-danger-text': __VLS_ctx.error }) },
|
||||
role: (__VLS_ctx.error ? 'alert' : undefined),
|
||||
});
|
||||
/** @type {__VLS_StyleScopedClasses['ks-danger-text']} */ ;
|
||||
(__VLS_ctx.error ?? __VLS_ctx.help);
|
||||
}
|
||||
// @ts-ignore
|
||||
var __VLS_1 = __VLS_0;
|
||||
// @ts-ignore
|
||||
[error, error, error, error, error, error, resolvedId, resolvedId, label, required, messageId, messageId, help, help,];
|
||||
const __VLS_base = (await import('vue')).defineComponent({
|
||||
__typeProps: {},
|
||||
});
|
||||
const __VLS_export = {};
|
||||
export default {};
|
||||
@@ -0,0 +1,56 @@
|
||||
import { useUiAdapter } from '../adapter/useUiAdapter';
|
||||
const __VLS_props = withDefaults(defineProps(), {
|
||||
severity: 'primary', type: 'button', disabled: false, loading: false
|
||||
});
|
||||
const emit = defineEmits();
|
||||
const adapter = useUiAdapter();
|
||||
const __VLS_defaults = {
|
||||
severity: 'primary', type: 'button', disabled: false, loading: false
|
||||
};
|
||||
const __VLS_ctx = {
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
};
|
||||
let __VLS_components;
|
||||
let __VLS_intrinsics;
|
||||
let __VLS_directives;
|
||||
const __VLS_0 = (__VLS_ctx.adapter.components.Button);
|
||||
// @ts-ignore
|
||||
const __VLS_1 = __VLS_asFunctionalComponent1(__VLS_0, new __VLS_0({
|
||||
...{ 'onActivate': {} },
|
||||
...(__VLS_ctx.$props),
|
||||
}));
|
||||
const __VLS_2 = __VLS_1({
|
||||
...{ 'onActivate': {} },
|
||||
...(__VLS_ctx.$props),
|
||||
}, ...__VLS_functionalComponentArgsRest(__VLS_1));
|
||||
let __VLS_5;
|
||||
const __VLS_6 = {
|
||||
/** @type {typeof __VLS_5.activate} */
|
||||
onActivate: (...[$event]) => {
|
||||
return (__VLS_ctx.emit('click', $event));
|
||||
// @ts-ignore
|
||||
[adapter, $props, emit,];
|
||||
},
|
||||
};
|
||||
var __VLS_7;
|
||||
const { default: __VLS_8 } = __VLS_3.slots;
|
||||
var __VLS_9 = {};
|
||||
// @ts-ignore
|
||||
[];
|
||||
var __VLS_3;
|
||||
var __VLS_4;
|
||||
// @ts-ignore
|
||||
var __VLS_10 = __VLS_9;
|
||||
// @ts-ignore
|
||||
[];
|
||||
const __VLS_base = (await import('vue')).defineComponent({
|
||||
__typeEmits: {},
|
||||
__typeProps: {},
|
||||
props: {},
|
||||
});
|
||||
const __VLS_export = {};
|
||||
export default {};
|
||||
@@ -0,0 +1,56 @@
|
||||
import { computed, useId } from 'vue';
|
||||
import { useUiAdapter } from '../adapter/useUiAdapter';
|
||||
const props = defineProps();
|
||||
const emit = defineEmits();
|
||||
const adapter = useUiAdapter();
|
||||
const generatedId = useId();
|
||||
const resolvedId = computed(() => props.inputId ?? `ks-check-${generatedId}`);
|
||||
const __VLS_ctx = {
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
};
|
||||
let __VLS_components;
|
||||
let __VLS_intrinsics;
|
||||
let __VLS_directives;
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.label, __VLS_intrinsics.label)({
|
||||
...{ class: "ks-check" },
|
||||
for: (__VLS_ctx.resolvedId),
|
||||
});
|
||||
/** @type {__VLS_StyleScopedClasses['ks-check']} */ ;
|
||||
const __VLS_0 = (__VLS_ctx.adapter.components.Checkbox);
|
||||
// @ts-ignore
|
||||
const __VLS_1 = __VLS_asFunctionalComponent1(__VLS_0, new __VLS_0({
|
||||
...{ 'onUpdate:modelValue': {} },
|
||||
inputId: (__VLS_ctx.resolvedId),
|
||||
modelValue: (__VLS_ctx.modelValue),
|
||||
disabled: (__VLS_ctx.disabled),
|
||||
}));
|
||||
const __VLS_2 = __VLS_1({
|
||||
...{ 'onUpdate:modelValue': {} },
|
||||
inputId: (__VLS_ctx.resolvedId),
|
||||
modelValue: (__VLS_ctx.modelValue),
|
||||
disabled: (__VLS_ctx.disabled),
|
||||
}, ...__VLS_functionalComponentArgsRest(__VLS_1));
|
||||
let __VLS_5;
|
||||
const __VLS_6 = {
|
||||
/** @type {typeof __VLS_5.'update:modelValue'} */
|
||||
'onUpdate:modelValue': (...[$event]) => {
|
||||
return (__VLS_ctx.emit('update:modelValue', $event));
|
||||
// @ts-ignore
|
||||
[resolvedId, resolvedId, adapter, modelValue, disabled, emit,];
|
||||
},
|
||||
};
|
||||
var __VLS_3;
|
||||
var __VLS_4;
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.span, __VLS_intrinsics.span)({});
|
||||
(__VLS_ctx.label);
|
||||
// @ts-ignore
|
||||
[label,];
|
||||
const __VLS_export = (await import('vue')).defineComponent({
|
||||
__typeEmits: {},
|
||||
__typeProps: {},
|
||||
});
|
||||
export default {};
|
||||
@@ -0,0 +1,58 @@
|
||||
import KsButton from './KsButton.vue';
|
||||
const __VLS_props = defineProps();
|
||||
const emit = defineEmits();
|
||||
const __VLS_ctx = {
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
};
|
||||
let __VLS_components;
|
||||
let __VLS_intrinsics;
|
||||
let __VLS_directives;
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.nav, __VLS_intrinsics.nav)({
|
||||
...{ class: "ks-command-bar" },
|
||||
'aria-label': (__VLS_ctx.ariaLabel ?? 'Page actions'),
|
||||
});
|
||||
/** @type {__VLS_StyleScopedClasses['ks-command-bar']} */ ;
|
||||
for (const [action] of __VLS_vFor((__VLS_ctx.actions))) {
|
||||
const __VLS_0 = KsButton;
|
||||
// @ts-ignore
|
||||
const __VLS_1 = __VLS_asFunctionalComponent1(__VLS_0, new __VLS_0({
|
||||
...{ 'onClick': {} },
|
||||
key: (action.id),
|
||||
label: (action.label),
|
||||
severity: (action.severity),
|
||||
disabled: (action.disabled),
|
||||
loading: (action.busy),
|
||||
}));
|
||||
const __VLS_2 = __VLS_1({
|
||||
...{ 'onClick': {} },
|
||||
key: (action.id),
|
||||
label: (action.label),
|
||||
severity: (action.severity),
|
||||
disabled: (action.disabled),
|
||||
loading: (action.busy),
|
||||
}, ...__VLS_functionalComponentArgsRest(__VLS_1));
|
||||
let __VLS_5;
|
||||
const __VLS_6 = {
|
||||
/** @type {typeof __VLS_5.click} */
|
||||
onClick: (...[$event]) => {
|
||||
return (__VLS_ctx.emit('execute', action.id));
|
||||
// @ts-ignore
|
||||
[ariaLabel, actions, emit,];
|
||||
},
|
||||
};
|
||||
var __VLS_3;
|
||||
var __VLS_4;
|
||||
// @ts-ignore
|
||||
[];
|
||||
}
|
||||
// @ts-ignore
|
||||
[];
|
||||
const __VLS_export = (await import('vue')).defineComponent({
|
||||
__typeEmits: {},
|
||||
__typeProps: {},
|
||||
});
|
||||
export default {};
|
||||
@@ -0,0 +1,68 @@
|
||||
import { computed } from 'vue';
|
||||
import EvidenceVersionSet from '../EvidenceVersionSet.vue';
|
||||
const props = defineProps();
|
||||
const versionSet = computed(() => ({
|
||||
datasetId: props.datasetId,
|
||||
dataHash: props.dataHash,
|
||||
modelVersion: props.modelVersion,
|
||||
configVersion: props.configVersion,
|
||||
codeSha: props.codeSha,
|
||||
contractVersion: props.contractVersion
|
||||
}));
|
||||
const __VLS_ctx = {
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
};
|
||||
let __VLS_components;
|
||||
let __VLS_intrinsics;
|
||||
let __VLS_directives;
|
||||
/** @type {__VLS_StyleScopedClasses['ks-data-context']} */ ;
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.header, __VLS_intrinsics.header)({
|
||||
...{ class: "ks-data-context" },
|
||||
'data-stale': (__VLS_ctx.stale || undefined),
|
||||
});
|
||||
/** @type {__VLS_StyleScopedClasses['ks-data-context']} */ ;
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.div, __VLS_intrinsics.div)({});
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.h1, __VLS_intrinsics.h1)({});
|
||||
(__VLS_ctx.title);
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.p, __VLS_intrinsics.p)({});
|
||||
(__VLS_ctx.asOf);
|
||||
if (__VLS_ctx.stale) {
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.strong, __VLS_intrinsics.strong)({});
|
||||
}
|
||||
const __VLS_0 = EvidenceVersionSet;
|
||||
// @ts-ignore
|
||||
const __VLS_1 = __VLS_asFunctionalComponent1(__VLS_0, new __VLS_0({
|
||||
value: (__VLS_ctx.versionSet),
|
||||
compact: true,
|
||||
}));
|
||||
const __VLS_2 = __VLS_1({
|
||||
value: (__VLS_ctx.versionSet),
|
||||
compact: true,
|
||||
}, ...__VLS_functionalComponentArgsRest(__VLS_1));
|
||||
if (__VLS_ctx.projectionVersion || __VLS_ctx.watermark || __VLS_ctx.correlationId) {
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.dl, __VLS_intrinsics.dl)({});
|
||||
if (__VLS_ctx.projectionVersion) {
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.dt, __VLS_intrinsics.dt)({});
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.dd, __VLS_intrinsics.dd)({});
|
||||
(__VLS_ctx.projectionVersion);
|
||||
}
|
||||
if (__VLS_ctx.watermark) {
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.dt, __VLS_intrinsics.dt)({});
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.dd, __VLS_intrinsics.dd)({});
|
||||
(__VLS_ctx.watermark);
|
||||
}
|
||||
if (__VLS_ctx.correlationId) {
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.dt, __VLS_intrinsics.dt)({});
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.dd, __VLS_intrinsics.dd)({});
|
||||
(__VLS_ctx.correlationId);
|
||||
}
|
||||
}
|
||||
// @ts-ignore
|
||||
[stale, stale, title, asOf, versionSet, projectionVersion, projectionVersion, projectionVersion, watermark, watermark, watermark, correlationId, correlationId, correlationId,];
|
||||
const __VLS_export = (await import('vue')).defineComponent({
|
||||
__typeProps: {},
|
||||
});
|
||||
export default {};
|
||||
@@ -0,0 +1,45 @@
|
||||
import { useUiAdapter } from '../adapter/useUiAdapter';
|
||||
const __VLS_props = withDefaults(defineProps(), { loading: false, height: '32rem', rowSelection: 'single' });
|
||||
const emit = defineEmits();
|
||||
const adapter = useUiAdapter();
|
||||
const __VLS_defaults = { loading: false, height: '32rem', rowSelection: 'single' };
|
||||
const __VLS_ctx = {
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
};
|
||||
let __VLS_components;
|
||||
let __VLS_intrinsics;
|
||||
let __VLS_directives;
|
||||
const __VLS_0 = (__VLS_ctx.adapter.components.DataGrid);
|
||||
// @ts-ignore
|
||||
const __VLS_1 = __VLS_asFunctionalComponent1(__VLS_0, new __VLS_0({
|
||||
...{ 'onRowSelected': {} },
|
||||
...(__VLS_ctx.$props),
|
||||
}));
|
||||
const __VLS_2 = __VLS_1({
|
||||
...{ 'onRowSelected': {} },
|
||||
...(__VLS_ctx.$props),
|
||||
}, ...__VLS_functionalComponentArgsRest(__VLS_1));
|
||||
let __VLS_5;
|
||||
const __VLS_6 = {
|
||||
/** @type {typeof __VLS_5.rowSelected} */
|
||||
onRowSelected: (...[$event]) => {
|
||||
return (__VLS_ctx.emit('rowSelected', $event));
|
||||
// @ts-ignore
|
||||
[adapter, $props, emit,];
|
||||
},
|
||||
};
|
||||
var __VLS_7;
|
||||
var __VLS_3;
|
||||
var __VLS_4;
|
||||
// @ts-ignore
|
||||
[];
|
||||
const __VLS_export = (await import('vue')).defineComponent({
|
||||
__typeEmits: {},
|
||||
__typeProps: {},
|
||||
props: {},
|
||||
});
|
||||
export default {};
|
||||
@@ -0,0 +1,88 @@
|
||||
import { computed, useId } from 'vue';
|
||||
import { useUiAdapter } from '../adapter/useUiAdapter';
|
||||
const props = defineProps();
|
||||
const emit = defineEmits();
|
||||
const adapter = useUiAdapter();
|
||||
const generatedId = useId();
|
||||
const resolvedId = computed(() => props.inputId ?? `ks-date-${generatedId}`);
|
||||
const __VLS_ctx = {
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
};
|
||||
let __VLS_components;
|
||||
let __VLS_intrinsics;
|
||||
let __VLS_directives;
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.div, __VLS_intrinsics.div)({
|
||||
...{ class: "ks-field" },
|
||||
});
|
||||
/** @type {__VLS_StyleScopedClasses['ks-field']} */ ;
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.label, __VLS_intrinsics.label)({
|
||||
for: (__VLS_ctx.resolvedId),
|
||||
});
|
||||
(__VLS_ctx.label);
|
||||
if (__VLS_ctx.required) {
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.span, __VLS_intrinsics.span)({
|
||||
'aria-hidden': "true",
|
||||
});
|
||||
}
|
||||
const __VLS_0 = (__VLS_ctx.adapter.components.DateField);
|
||||
// @ts-ignore
|
||||
const __VLS_1 = __VLS_asFunctionalComponent1(__VLS_0, new __VLS_0({
|
||||
...{ 'onUpdate:modelValue': {} },
|
||||
...{ 'onBlur': {} },
|
||||
inputId: (__VLS_ctx.resolvedId),
|
||||
modelValue: (__VLS_ctx.modelValue),
|
||||
disabled: (__VLS_ctx.disabled),
|
||||
invalid: (Boolean(__VLS_ctx.error)),
|
||||
min: (__VLS_ctx.min),
|
||||
max: (__VLS_ctx.max),
|
||||
'aria-describedby': (__VLS_ctx.error || __VLS_ctx.help ? `${__VLS_ctx.resolvedId}-message` : undefined),
|
||||
}));
|
||||
const __VLS_2 = __VLS_1({
|
||||
...{ 'onUpdate:modelValue': {} },
|
||||
...{ 'onBlur': {} },
|
||||
inputId: (__VLS_ctx.resolvedId),
|
||||
modelValue: (__VLS_ctx.modelValue),
|
||||
disabled: (__VLS_ctx.disabled),
|
||||
invalid: (Boolean(__VLS_ctx.error)),
|
||||
min: (__VLS_ctx.min),
|
||||
max: (__VLS_ctx.max),
|
||||
'aria-describedby': (__VLS_ctx.error || __VLS_ctx.help ? `${__VLS_ctx.resolvedId}-message` : undefined),
|
||||
}, ...__VLS_functionalComponentArgsRest(__VLS_1));
|
||||
let __VLS_5;
|
||||
const __VLS_6 = {
|
||||
/** @type {typeof __VLS_5.'update:modelValue'} */
|
||||
'onUpdate:modelValue': (...[$event]) => {
|
||||
return (__VLS_ctx.emit('update:modelValue', $event));
|
||||
// @ts-ignore
|
||||
[resolvedId, resolvedId, resolvedId, label, required, adapter, modelValue, disabled, error, error, min, max, help, emit,];
|
||||
},
|
||||
};
|
||||
const __VLS_7 = {
|
||||
/** @type {typeof __VLS_5.blur} */
|
||||
onBlur: (...[$event]) => {
|
||||
return (__VLS_ctx.emit('blur', $event));
|
||||
// @ts-ignore
|
||||
[emit,];
|
||||
},
|
||||
};
|
||||
var __VLS_3;
|
||||
var __VLS_4;
|
||||
if (__VLS_ctx.error || __VLS_ctx.help) {
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.small, __VLS_intrinsics.small)({
|
||||
id: (`${__VLS_ctx.resolvedId}-message`),
|
||||
...{ class: ({ 'ks-danger-text': __VLS_ctx.error }) },
|
||||
});
|
||||
/** @type {__VLS_StyleScopedClasses['ks-danger-text']} */ ;
|
||||
(__VLS_ctx.error ?? __VLS_ctx.help);
|
||||
}
|
||||
// @ts-ignore
|
||||
[resolvedId, error, error, error, help, help,];
|
||||
const __VLS_export = (await import('vue')).defineComponent({
|
||||
__typeEmits: {},
|
||||
__typeProps: {},
|
||||
});
|
||||
export default {};
|
||||
@@ -0,0 +1,56 @@
|
||||
import { useUiAdapter } from '../adapter/useUiAdapter';
|
||||
const __VLS_props = defineProps();
|
||||
const emit = defineEmits();
|
||||
const adapter = useUiAdapter();
|
||||
const __VLS_ctx = {
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
};
|
||||
let __VLS_components;
|
||||
let __VLS_intrinsics;
|
||||
let __VLS_directives;
|
||||
const __VLS_0 = (__VLS_ctx.adapter.components.Dialog);
|
||||
// @ts-ignore
|
||||
const __VLS_1 = __VLS_asFunctionalComponent1(__VLS_0, new __VLS_0({
|
||||
...{ 'onUpdate:visible': {} },
|
||||
...(__VLS_ctx.$props),
|
||||
}));
|
||||
const __VLS_2 = __VLS_1({
|
||||
...{ 'onUpdate:visible': {} },
|
||||
...(__VLS_ctx.$props),
|
||||
}, ...__VLS_functionalComponentArgsRest(__VLS_1));
|
||||
let __VLS_5;
|
||||
const __VLS_6 = {
|
||||
/** @type {typeof __VLS_5.'update:visible'} */
|
||||
'onUpdate:visible': (...[$event]) => {
|
||||
return (__VLS_ctx.emit('update:visible', $event));
|
||||
// @ts-ignore
|
||||
[adapter, $props, emit,];
|
||||
},
|
||||
};
|
||||
var __VLS_7;
|
||||
const { default: __VLS_8 } = __VLS_3.slots;
|
||||
var __VLS_9 = {};
|
||||
{
|
||||
const { footer: __VLS_11 } = __VLS_3.slots;
|
||||
var __VLS_12 = {};
|
||||
// @ts-ignore
|
||||
[];
|
||||
}
|
||||
// @ts-ignore
|
||||
[];
|
||||
var __VLS_3;
|
||||
var __VLS_4;
|
||||
// @ts-ignore
|
||||
var __VLS_10 = __VLS_9, __VLS_13 = __VLS_12;
|
||||
// @ts-ignore
|
||||
[];
|
||||
const __VLS_base = (await import('vue')).defineComponent({
|
||||
__typeEmits: {},
|
||||
__typeProps: {},
|
||||
});
|
||||
const __VLS_export = {};
|
||||
export default {};
|
||||
@@ -0,0 +1,45 @@
|
||||
import { useUiAdapter } from '../adapter/useUiAdapter';
|
||||
const __VLS_props = withDefaults(defineProps(), { severity: 'info', dismissible: false });
|
||||
const emit = defineEmits();
|
||||
const adapter = useUiAdapter();
|
||||
const __VLS_defaults = { severity: 'info', dismissible: false };
|
||||
const __VLS_ctx = {
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
};
|
||||
let __VLS_components;
|
||||
let __VLS_intrinsics;
|
||||
let __VLS_directives;
|
||||
const __VLS_0 = (__VLS_ctx.adapter.components.InlineMessage);
|
||||
// @ts-ignore
|
||||
const __VLS_1 = __VLS_asFunctionalComponent1(__VLS_0, new __VLS_0({
|
||||
...{ 'onDismiss': {} },
|
||||
...(__VLS_ctx.$props),
|
||||
}));
|
||||
const __VLS_2 = __VLS_1({
|
||||
...{ 'onDismiss': {} },
|
||||
...(__VLS_ctx.$props),
|
||||
}, ...__VLS_functionalComponentArgsRest(__VLS_1));
|
||||
let __VLS_5;
|
||||
const __VLS_6 = {
|
||||
/** @type {typeof __VLS_5.dismiss} */
|
||||
onDismiss: (...[$event]) => {
|
||||
return (__VLS_ctx.emit('dismiss'));
|
||||
// @ts-ignore
|
||||
[adapter, $props, emit,];
|
||||
},
|
||||
};
|
||||
var __VLS_7;
|
||||
var __VLS_3;
|
||||
var __VLS_4;
|
||||
// @ts-ignore
|
||||
[];
|
||||
const __VLS_export = (await import('vue')).defineComponent({
|
||||
__typeEmits: {},
|
||||
__typeProps: {},
|
||||
props: {},
|
||||
});
|
||||
export default {};
|
||||
@@ -0,0 +1,45 @@
|
||||
import { useUiAdapter } from '../adapter/useUiAdapter';
|
||||
const __VLS_props = withDefaults(defineProps(), { modelValue: () => [] });
|
||||
const emit = defineEmits();
|
||||
const adapter = useUiAdapter();
|
||||
const __VLS_defaults = { modelValue: () => [] };
|
||||
const __VLS_ctx = {
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
};
|
||||
let __VLS_components;
|
||||
let __VLS_intrinsics;
|
||||
let __VLS_directives;
|
||||
const __VLS_0 = (__VLS_ctx.adapter.components.MultiSelect);
|
||||
// @ts-ignore
|
||||
const __VLS_1 = __VLS_asFunctionalComponent1(__VLS_0, new __VLS_0({
|
||||
...{ 'onUpdate:modelValue': {} },
|
||||
...(__VLS_ctx.$props),
|
||||
}));
|
||||
const __VLS_2 = __VLS_1({
|
||||
...{ 'onUpdate:modelValue': {} },
|
||||
...(__VLS_ctx.$props),
|
||||
}, ...__VLS_functionalComponentArgsRest(__VLS_1));
|
||||
let __VLS_5;
|
||||
const __VLS_6 = {
|
||||
/** @type {typeof __VLS_5.'update:modelValue'} */
|
||||
'onUpdate:modelValue': (...[$event]) => {
|
||||
return (__VLS_ctx.emit('update:modelValue', $event));
|
||||
// @ts-ignore
|
||||
[adapter, $props, emit,];
|
||||
},
|
||||
};
|
||||
var __VLS_7;
|
||||
var __VLS_3;
|
||||
var __VLS_4;
|
||||
// @ts-ignore
|
||||
[];
|
||||
const __VLS_export = (await import('vue')).defineComponent({
|
||||
__typeEmits: {},
|
||||
__typeProps: {},
|
||||
props: {},
|
||||
});
|
||||
export default {};
|
||||
@@ -0,0 +1,92 @@
|
||||
import { computed, useId } from 'vue';
|
||||
import { useUiAdapter } from '../adapter/useUiAdapter';
|
||||
const props = defineProps();
|
||||
const emit = defineEmits();
|
||||
const adapter = useUiAdapter();
|
||||
const generatedId = useId();
|
||||
const resolvedId = computed(() => props.inputId ?? `ks-number-${generatedId}`);
|
||||
const __VLS_ctx = {
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
...{},
|
||||
};
|
||||
let __VLS_components;
|
||||
let __VLS_intrinsics;
|
||||
let __VLS_directives;
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.div, __VLS_intrinsics.div)({
|
||||
...{ class: "ks-field" },
|
||||
});
|
||||
/** @type {__VLS_StyleScopedClasses['ks-field']} */ ;
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.label, __VLS_intrinsics.label)({
|
||||
for: (__VLS_ctx.resolvedId),
|
||||
});
|
||||
(__VLS_ctx.label);
|
||||
if (__VLS_ctx.required) {
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.span, __VLS_intrinsics.span)({
|
||||
'aria-hidden': "true",
|
||||
});
|
||||
}
|
||||
const __VLS_0 = (__VLS_ctx.adapter.components.NumberField);
|
||||
// @ts-ignore
|
||||
const __VLS_1 = __VLS_asFunctionalComponent1(__VLS_0, new __VLS_0({
|
||||
...{ 'onUpdate:modelValue': {} },
|
||||
...{ 'onBlur': {} },
|
||||
inputId: (__VLS_ctx.resolvedId),
|
||||
modelValue: (__VLS_ctx.modelValue),
|
||||
disabled: (__VLS_ctx.disabled),
|
||||
invalid: (Boolean(__VLS_ctx.error)),
|
||||
min: (__VLS_ctx.min),
|
||||
max: (__VLS_ctx.max),
|
||||
minFractionDigits: (__VLS_ctx.minFractionDigits),
|
||||
maxFractionDigits: (__VLS_ctx.maxFractionDigits),
|
||||
'aria-describedby': (__VLS_ctx.error || __VLS_ctx.help ? `${__VLS_ctx.resolvedId}-message` : undefined),
|
||||
}));
|
||||
const __VLS_2 = __VLS_1({
|
||||
...{ 'onUpdate:modelValue': {} },
|
||||
...{ 'onBlur': {} },
|
||||
inputId: (__VLS_ctx.resolvedId),
|
||||
modelValue: (__VLS_ctx.modelValue),
|
||||
disabled: (__VLS_ctx.disabled),
|
||||
invalid: (Boolean(__VLS_ctx.error)),
|
||||
min: (__VLS_ctx.min),
|
||||
max: (__VLS_ctx.max),
|
||||
minFractionDigits: (__VLS_ctx.minFractionDigits),
|
||||
maxFractionDigits: (__VLS_ctx.maxFractionDigits),
|
||||
'aria-describedby': (__VLS_ctx.error || __VLS_ctx.help ? `${__VLS_ctx.resolvedId}-message` : undefined),
|
||||
}, ...__VLS_functionalComponentArgsRest(__VLS_1));
|
||||
let __VLS_5;
|
||||
const __VLS_6 = {
|
||||
/** @type {typeof __VLS_5.'update:modelValue'} */
|
||||
'onUpdate:modelValue': (...[$event]) => {
|
||||
return (__VLS_ctx.emit('update:modelValue', $event));
|
||||
// @ts-ignore
|
||||
[resolvedId, resolvedId, resolvedId, label, required, adapter, modelValue, disabled, error, error, min, max, minFractionDigits, maxFractionDigits, help, emit,];
|
||||
},
|
||||
};
|
||||
const __VLS_7 = {
|
||||
/** @type {typeof __VLS_5.blur} */
|
||||
onBlur: (...[$event]) => {
|
||||
return (__VLS_ctx.emit('blur', $event));
|
||||
// @ts-ignore
|
||||
[emit,];
|
||||
},
|
||||
};
|
||||
var __VLS_3;
|
||||
var __VLS_4;
|
||||
if (__VLS_ctx.error || __VLS_ctx.help) {
|
||||
__VLS_asFunctionalElement1(__VLS_intrinsics.small, __VLS_intrinsics.small)({
|
||||
id: (`${__VLS_ctx.resolvedId}-message`),
|
||||
...{ class: ({ 'ks-danger-text': __VLS_ctx.error }) },
|
||||
});
|
||||
/** @type {__VLS_StyleScopedClasses['ks-danger-text']} */ ;
|
||||
(__VLS_ctx.error ?? __VLS_ctx.help);
|
||||
}
|
||||
// @ts-ignore
|
||||
[resolvedId, error, error, error, help, help,];
|
||||
const __VLS_export = (await import('vue')).defineComponent({
|
||||
__typeEmits: {},
|
||||
__typeProps: {},
|
||||
});
|
||||
export default {};
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user