diff --git a/app/game-api/src/router/world/index.ts b/app/game-api/src/router/world/index.ts index 36b82562..75b97c7f 100644 --- a/app/game-api/src/router/world/index.ts +++ b/app/game-api/src/router/world/index.ts @@ -175,13 +175,14 @@ export const worldRouter = router({ const turns = generalIds.length ? await ctx.db.generalTurn.findMany({ where: { generalId: { in: generalIds }, turnIdx: { lt: 5 } }, + select: { generalId: true, turnIdx: true, actionCode: true, arg: true }, orderBy: [{ generalId: 'asc' }, { turnIdx: 'asc' }], }) : []; - const turnMap = new Map(); + const turnMap = new Map>(); for (const turn of turns) { const list = turnMap.get(turn.generalId) ?? []; - list[turn.turnIdx] = turn.actionCode; + list[turn.turnIdx] = { action: turn.actionCode, args: turn.arg }; turnMap.set(turn.generalId, list); } const nationMap = new Map(nations.map((item) => [item.id, item])); diff --git a/app/game-api/test/worldCurrentCityRouter.test.ts b/app/game-api/test/worldCurrentCityRouter.test.ts new file mode 100644 index 00000000..36b84234 --- /dev/null +++ b/app/game-api/test/worldCurrentCityRouter.test.ts @@ -0,0 +1,175 @@ +import { describe, expect, it, vi } from 'vitest'; + +import type { GameSessionTokenPayload } from '@sammo-ts/common/auth/gameToken'; +import type { RedisConnector } from '@sammo-ts/infra'; + +import { RedisAccessTokenStore } from '../src/auth/accessTokenStore.js'; +import { InMemoryFlushStore } from '../src/auth/flushStore.js'; +import type { DatabaseClient, GameApiContext, GeneralRow } from '../src/context.js'; +import { appRouter } from '../src/router.js'; + +vi.mock('../src/maps/mapLayout.js', () => ({ + loadMapLayout: vi.fn(async () => ({ + mapName: 'che', + cityList: [{ id: 1, name: '업', level: 8, region: 1, x: 0, y: 0, path: [] }], + regionMap: { 1: '하북' }, + levelMap: { 8: '특' }, + })), +})); + +vi.mock('@sammo-ts/game-engine/scenario/unitSetLoader.js', () => ({ + loadUnitSetDefinitionByName: vi.fn(async () => ({ crewTypes: [{ id: 1, name: '보병' }] })), +})); + +const now = new Date('2026-01-01T01:02:00Z'); +const general = (overrides: Partial = {}): GeneralRow => ({ + id: 1, + userId: 'u1', + name: '장수', + nationId: 1, + cityId: 1, + troopId: 0, + npcState: 0, + affinity: null, + bornYear: 180, + deadYear: 300, + picture: null, + imageServer: 0, + leadership: 70, + strength: 60, + intel: 50, + injury: 0, + experience: 900, + dedication: 100, + officerLevel: 1, + gold: 1000, + rice: 2000, + crew: 300, + crewTypeId: 1, + train: 90, + atmos: 90, + weaponCode: 'None', + bookCode: 'None', + horseCode: 'None', + itemCode: 'None', + turnTime: now, + recentWarTime: null, + age: 20, + startAge: 20, + personalCode: 'None', + specialCode: 'None', + special2Code: 'None', + lastTurn: {}, + meta: { defence_train: 80 }, + penalty: {}, + createdAt: now, + updatedAt: now, + ...overrides, +}); + +const token = (): GameSessionTokenPayload => ({ + version: 1, + profile: 'che:default', + issuedAt: now.toISOString(), + expiresAt: new Date(now.getTime() + 86_400_000).toISOString(), + sessionId: 'session-1', + user: { id: 'u1', username: 'u1', displayName: '장수', roles: [] }, + sanctions: {}, +}); + +const fixture = (authenticated = true) => { + const actor = general(); + const npc = general({ id: 2, userId: null, name: 'NPC', npcState: 2 }); + const city = { + id: 1, + name: '업', + nationId: 1, + level: 8, + region: 1, + population: 150_000, + populationMax: 620_500, + agriculture: 1_000, + agricultureMax: 12_500, + commerce: 1_000, + commerceMax: 11_300, + security: 1_000, + securityMax: 10_000, + trust: 80, + trade: 100, + defence: 5_000, + defenceMax: 11_700, + wall: 5_000, + wallMax: 12_200, + }; + const db = { + general: { + findFirst: vi.fn(async () => actor), + findMany: vi.fn(async ({ where }: { where: Record }) => { + if ('cityId' in where) return [actor, npc]; + if ('officerLevel' in where) return []; + if ('nationId' in where) return [actor, npc]; + return []; + }), + }, + nation: { + findUnique: vi.fn(async () => ({ id: 1, name: '위', color: '#008000', level: 1, meta: {} })), + findMany: vi.fn(async () => [{ id: 1, name: '위', color: '#008000', level: 1, meta: {} }]), + }, + city: { findMany: vi.fn(async () => [city]) }, + worldState: { + findFirst: vi.fn(async () => ({ config: {}, meta: { turntime: '2026-01-01 10:02:00' } })), + }, + generalTurn: { + findMany: vi.fn(async () => [ + { + generalId: 1, + turnIdx: 0, + actionCode: 'che_징병', + arg: { crewType: 1, amount: 300 }, + }, + ]), + }, + }; + const redis = { get: vi.fn(async () => null), set: vi.fn(async () => null) } as unknown as RedisConnector['client']; + const context: GameApiContext = { + db: db as unknown as DatabaseClient, + redis, + turnDaemon: {} as GameApiContext['turnDaemon'], + battleSim: {} as GameApiContext['battleSim'], + profile: { id: 'che', scenario: 'default', name: 'che:default' }, + auth: authenticated ? token() : null, + uploadDir: 'uploads', + uploadPath: '/uploads', + uploadPublicUrl: null, + accessTokenStore: new RedisAccessTokenStore(redis, 'che:default'), + flushStore: new InMemoryFlushStore(), + gameTokenSecret: 'secret', + }; + return { caller: appRouter.createCaller(context), db }; +}; + +describe('world current-city command projection', () => { + it('returns the first five own-user turns as canonical action and args while redacting NPC turns', async () => { + const { caller, db } = fixture(); + + const result = await caller.world.getCurrentCity(); + + expect(result.generals.find((entry) => entry.id === 1)?.turns).toEqual([ + { action: 'che_징병', args: { crewType: 1, amount: 300 } }, + ]); + expect(result.generals.find((entry) => entry.id === 2)?.turns).toEqual([]); + expect(db.generalTurn.findMany).toHaveBeenCalledWith( + expect.objectContaining({ + where: { generalId: { in: [1] }, turnIdx: { lt: 5 } }, + select: { generalId: true, turnIdx: true, actionCode: true, arg: true }, + }) + ); + }); + + it('keeps authentication and input validation in front of the city read model', async () => { + await expect(fixture(false).caller.world.getCurrentCity()).rejects.toMatchObject({ code: 'UNAUTHORIZED' }); + await expect(fixture().caller.world.getCurrentCity({ cityId: 0 })).rejects.toMatchObject({ + code: 'BAD_REQUEST', + }); + }); +}); diff --git a/app/game-engine/test/scenarioSeeder.test.ts b/app/game-engine/test/scenarioSeeder.test.ts index 10ea88b4..112b16a1 100644 --- a/app/game-engine/test/scenarioSeeder.test.ts +++ b/app/game-engine/test/scenarioSeeder.test.ts @@ -349,7 +349,7 @@ describeDb('scenario database seed', () => { databaseUrl, now: new Date('2030-01-01T00:00:00Z'), installOptions: { - turnTermMinutes: 60, + turnTermMinutes: 3, sync: false, fiction: 1, extend: false, @@ -383,7 +383,7 @@ describeDb('scenario database seed', () => { if (!worldState) { return; } - expect(worldState.tickSeconds).toBe(3600); + expect(worldState.tickSeconds).toBe(180); expect(worldState.currentMonth).toBe(1); const config = (worldState.config ?? {}) as Record; @@ -395,7 +395,7 @@ describeDb('scenario database seed', () => { expect(meta.develcost).toBe( (worldState.currentYear - (scenario.startYear ?? worldState.currentYear) + 10) * 2 ); - expect(meta.killturn).toBe(80); + expect(meta.killturn).toBe(1600); const autorun = (meta.autorun_user ?? {}) as Record; const autorunOptions = (autorun.options ?? {}) as Record; expect(autorunOptions.develop).toBe(true); diff --git a/app/game-frontend/e2e/inGameInfo.spec.ts b/app/game-frontend/e2e/inGameInfo.spec.ts index e90843f6..2270d1ce 100644 --- a/app/game-frontend/e2e/inGameInfo.spec.ts +++ b/app/game-frontend/e2e/inGameInfo.spec.ts @@ -210,7 +210,44 @@ const install = async ( } if (operation === 'general.me') return response(generalContext); if (operation === 'world.getMap') return response(mapFixture); - if (operation === 'turns.getCommandTable') return response({ general: [], nation: [] }); + if (operation === 'turns.getCommandTable') + return response({ + general: [ + { + category: '군사', + values: [ + { + key: 'che_징병', + name: '징병', + reqArg: true, + status: 'needsInput', + possible: true, + inputFields: [], + }, + { + key: 'che_화계', + name: '화계', + reqArg: true, + status: 'needsInput', + possible: true, + inputFields: [], + }, + ], + }, + ], + nation: [], + inputOptions: { + cities: [{ value: 1, label: '업 (아국)' }], + nations: [], + generals: [], + crewTypes: [{ value: 1, label: '보병' }], + armTypes: [], + nationTypes: [], + colors: [], + items: {}, + recruitment: null, + }, + }); if (operation === 'turns.reserved.getGeneral' || operation === 'turns.reserved.getNation') { return response({ turns: [], revision: 0 }); } @@ -373,7 +410,12 @@ const install = async ( crew: 500, train: 90, atmos: 90, - turns: denseCurrentCity ? ['징병', '훈련'] : ['징병'], + turns: denseCurrentCity + ? [ + { action: 'che_징병', args: { crewType: 1, amount: 300 } }, + { action: 'che_화계', args: { destCityId: 1 } }, + ] + : [{ action: 'che_징병', args: { crewType: 1, amount: 300 } }], }, ...(denseCurrentCity ? Array.from({ length: 12 }, (_, index) => ({ @@ -1082,8 +1124,10 @@ test('current-city wraps dense general names and only shrinks reserved turns', a const rows = page.locator('.generals tbody tr'); const reservedTurns = rows.nth(0).locator('.turns'); const npcTurns = rows.nth(1).locator('.turns'); - await expect(reservedTurns).toContainText('1 : 징병'); - await expect(reservedTurns).toContainText('2 : 훈련'); + await expect(reservedTurns).toContainText('1 : 【보병】 300명 징병'); + await expect(reservedTurns).toContainText('2 : 【업】에 화계실행'); + await expect(reservedTurns.locator('.turn-line').nth(0)).toHaveAttribute('title', '【보병】 300명 징병'); + await expect(reservedTurns.locator('.turn-line').nth(1)).toHaveAttribute('title', '【업】에 화계실행'); await expect(reservedTurns).toHaveClass(/turns--reserved/); await expect(npcTurns).toHaveText('NPC 장수'); await expect(npcTurns).not.toHaveClass(/turns--reserved/); diff --git a/app/game-frontend/e2e/mainNavigation.spec.ts b/app/game-frontend/e2e/mainNavigation.spec.ts index 03fd3d7a..ff55f750 100644 --- a/app/game-frontend/e2e/mainNavigation.spec.ts +++ b/app/game-frontend/e2e/mainNavigation.spec.ts @@ -2218,7 +2218,43 @@ test('main cards and command input stay inside their Ref-sized grid slots', asyn await selectedMenu.evaluate((element) => ((element as HTMLDetailsElement).open = false)); await expect(selectedMenu).not.toHaveAttribute('open', ''); - await page.locator('[data-main-target="commands"] .select-command').click(); + const selectCommand = page.locator('[data-main-target="commands"] .select-command'); + await expect(selectCommand).toHaveClass(/legacy-button--info/u); + await page.mouse.move(1, 1); + const measureSelectCommand = () => + selectCommand.evaluate((element) => { + const rect = element.getBoundingClientRect(); + const style = getComputedStyle(element); + return { + top: rect.top, + bottom: rect.bottom, + height: rect.height, + marginTop: style.marginTop, + borderBottomWidth: style.borderBottomWidth, + borderRadius: style.borderRadius, + backgroundColor: style.backgroundColor, + }; + }); + const selectDefault = await measureSelectCommand(); + expect(selectDefault).toMatchObject({ + height: 34, + marginTop: '0px', + borderBottomWidth: '4px', + borderRadius: '5.25px', + backgroundColor: 'rgb(52, 152, 219)', + }); + await selectCommand.hover(); + const selectHover = await measureSelectCommand(); + expect(selectHover).toMatchObject({ height: 33, marginTop: '1px', borderBottomWidth: '3px' }); + expect(selectHover.bottom).toBeCloseTo(selectDefault.bottom, 2); + const selectBox = await selectCommand.boundingBox(); + if (!selectBox) throw new Error('select command control is not measurable'); + await page.mouse.move(selectBox.x + selectBox.width / 2, selectBox.y + selectBox.height / 2); + await page.mouse.down(); + const selectActive = await measureSelectCommand(); + expect(selectActive).toMatchObject({ height: 32, marginTop: '2px', borderBottomWidth: '2px' }); + expect(selectActive.bottom).toBeCloseTo(selectDefault.bottom, 2); + await page.mouse.up(); const picker = page.getByTestId('command-picker'); await expect(picker).toBeVisible(); // The trigger can end up directly above a newly opened category button. diff --git a/app/game-frontend/e2e/nationGeneralSecret.spec.ts b/app/game-frontend/e2e/nationGeneralSecret.spec.ts index 906c40d2..47f4426c 100644 --- a/app/game-frontend/e2e/nationGeneralSecret.spec.ts +++ b/app/game-frontend/e2e/nationGeneralSecret.spec.ts @@ -205,6 +205,86 @@ test('nation generals keeps the 1000px legacy grid and redacted member columns', await expect(page.locator('#nation-general-list')).toContainText('?'); }); +test('nation generals top controls share fixed Lumen state geometry on desktop and mobile', async ({ + page, +}, testInfo) => { + await install(page); + const evidence: Record = {}; + + for (const viewport of [ + { width: 1200, height: 900 }, + { width: 500, height: 900 }, + ]) { + await page.setViewportSize(viewport); + await page.goto('nation/generals'); + await expect(page.locator('#nation-general-list')).toBeVisible(); + const controls = [ + page.getByRole('button', { name: '돌아가기' }), + page.getByRole('button', { name: '갱신' }), + page.getByRole('button', { name: '보기 모드⌄' }), + page.getByRole('button', { name: '열 선택⌄' }), + ]; + const viewportEvidence: Record = {}; + + for (const control of controls) { + const label = (await control.textContent())?.trim() ?? 'unknown'; + await expect(control).toHaveClass(/legacy-button--fixed-height/u); + const measure = () => + control.evaluate((element) => { + const rect = element.getBoundingClientRect(); + const style = getComputedStyle(element); + return { + top: rect.top, + bottom: rect.bottom, + height: rect.height, + marginTop: style.marginTop, + borderBottomWidth: style.borderBottomWidth, + borderRadius: style.borderRadius, + backgroundColor: style.backgroundColor, + fontFamily: style.fontFamily, + fontSize: style.fontSize, + }; + }); + await page.mouse.move(viewport.width - 1, viewport.height - 1); + const base = await measure(); + expect(base).toMatchObject({ + height: 32, + marginTop: '0px', + borderBottomWidth: '4px', + borderRadius: '5.25px', + fontSize: '14px', + }); + expect(base.fontFamily).toContain('Pretendard'); + + await control.hover(); + const hover = await measure(); + expect(hover).toMatchObject({ height: 31, marginTop: '1px', borderBottomWidth: '3px' }); + expect(hover.bottom).toBeCloseTo(base.bottom, 2); + + const box = await control.boundingBox(); + if (!box) throw new Error(`${label} control is not measurable`); + await page.mouse.move(box.x + box.width / 2, box.y + box.height / 2); + await page.mouse.down(); + const active = await measure(); + expect(active).toMatchObject({ height: 30, marginTop: '2px', borderBottomWidth: '2px' }); + expect(active.bottom).toBeCloseTo(base.bottom, 2); + await page.mouse.move(viewport.width - 1, viewport.height - 1); + await page.mouse.up(); + viewportEvidence[label] = { default: base, hover, active }; + } + evidence[`${viewport.width}x${viewport.height}`] = viewportEvidence; + await page.screenshot({ + path: testInfo.outputPath(`nation-general-buttons-${viewport.width}.png`), + fullPage: true, + }); + } + + await testInfo.attach('nation-general-button-geometry', { + body: JSON.stringify(evidence, null, 2), + contentType: 'application/json', + }); +}); + test('nation generals restores Ref group, saved view, sort, and Korean search behavior', async ({ page }, testInfo) => { await install(page); await page.setViewportSize({ width: 1200, height: 900 }); @@ -405,17 +485,20 @@ test('secret office renders five Ref-style command briefs and the forbidden erro '5 : 휴식', ]); await expect(commandRows.nth(2)).toHaveAttribute('title', '【다른장수】에게 쌀 200을 증여'); - const geometry = await page.locator('#secret-general-list .turns').first().evaluate((element) => { - const rect = element.getBoundingClientRect(); - const style = getComputedStyle(element); - return { - width: rect.width, - height: rect.height, - fontSize: style.fontSize, - textAlign: style.textAlign, - horizontalOverflow: element.scrollWidth - element.clientWidth, - }; - }); + const geometry = await page + .locator('#secret-general-list .turns') + .first() + .evaluate((element) => { + const rect = element.getBoundingClientRect(); + const style = getComputedStyle(element); + return { + width: rect.width, + height: rect.height, + fontSize: style.fontSize, + textAlign: style.textAlign, + horizontalOverflow: element.scrollWidth - element.clientWidth, + }; + }); expect(geometry.width).toBeGreaterThanOrEqual(190); expect(geometry.width).toBeLessThanOrEqual(230); expect(geometry.height).toBeGreaterThanOrEqual(60); diff --git a/app/game-frontend/e2e/tournamentBracket.spec.ts b/app/game-frontend/e2e/tournamentBracket.spec.ts index 1b539f13..9fa44672 100644 --- a/app/game-frontend/e2e/tournamentBracket.spec.ts +++ b/app/game-frontend/e2e/tournamentBracket.spec.ts @@ -395,7 +395,10 @@ test('join refresh shows the assigned preliminary group immediately with accessi await refresh.focus(); await expect(refresh).toBeFocused(); await refresh.hover(); - await expect(refresh).toHaveCSS('filter', 'brightness(1.25)'); + await expect(refresh).toHaveCSS('filter', 'none'); + await expect(refresh).toHaveCSS('height', '43px'); + await expect(refresh).toHaveCSS('margin-top', '1px'); + await expect(refresh).toHaveCSS('border-bottom-width', '3px'); expect(await page.evaluate(() => document.documentElement.scrollWidth)).toBeLessThanOrEqual(390); }); @@ -602,7 +605,11 @@ test('mobile betting rankings use tabs and keep dedicated icons beside general n await expect(dialog.getByText('예상 환수금 280')).toBeVisible(); await dialog.getByLabel('베팅 금액').selectOption('50'); await expect(dialog.getByText('예상 환수금 1,400')).toBeVisible(); - await persistScreenshot(page, 'tournament-betting-dialog-mobile', testInfo.outputPath('betting-dialog-mobile.webp')); + await persistScreenshot( + page, + 'tournament-betting-dialog-mobile', + testInfo.outputPath('betting-dialog-mobile.webp') + ); await dialog.getByRole('button', { name: '베팅 등록' }).click(); await expect(dialog).not.toBeVisible(); await expect(page.getByRole('status')).toHaveText('베팅이 등록되었습니다.'); diff --git a/app/game-frontend/src/assets/styles/legacy-controls.css b/app/game-frontend/src/assets/styles/legacy-controls.css index b7111403..2b2fcba0 100644 --- a/app/game-frontend/src/assets/styles/legacy-controls.css +++ b/app/game-frontend/src/assets/styles/legacy-controls.css @@ -144,7 +144,7 @@ /* * Ref Bootstrap 5.2 + Lumen button family. This class owns the common raised * edge and pressed movement. Semantic modifiers below only select face, edge, - * and text colors; width and fixed-height compensation stay with the owner. + * and text colors; width and the optional fixed-height value stay with the owner. * Existing semantic modifiers also opt in for backward compatibility. */ .legacy-button:is( @@ -173,6 +173,15 @@ vertical-align: middle; } +/* + * Top bars and other fixed rows keep their owner-provided height while using + * the same Lumen edge movement. Shrinking the box with the edge keeps its + * bottom coordinate fixed instead of moving the whole control down. + */ +.legacy-button.legacy-button--fixed-height { + height: var(--legacy-button-height); +} + .legacy-button.legacy-button--secondary { --legacy-button-bg: var(--sammo-button-secondary-bg); --legacy-button-border: var(--sammo-button-secondary-border); @@ -213,6 +222,10 @@ background: var(--legacy-button-bg); } +.legacy-button.legacy-button--fixed-height:not(:disabled, [aria-disabled='true']):is(:hover, [aria-expanded='true']) { + height: calc(var(--legacy-button-height) - 1px); +} + .legacy-button:is( .legacy-button--lumen, .legacy-button--primary, @@ -244,6 +257,10 @@ box-shadow: none; } +.legacy-button.legacy-button--fixed-height:not(:disabled, [aria-disabled='true']):active { + height: calc(var(--legacy-button-height) - 2px); +} + .legacy-button:is( .legacy-button--lumen, .legacy-button--primary, diff --git a/app/game-frontend/src/components/command/ReservedCommandEditor.vue b/app/game-frontend/src/components/command/ReservedCommandEditor.vue index 0fc29698..b7ff6956 100644 --- a/app/game-frontend/src/components/command/ReservedCommandEditor.vue +++ b/app/game-frontend/src/components/command/ReservedCommandEditor.vue @@ -588,7 +588,13 @@ const clickOutsideMenu = (event: Event) => { - +
@@ -806,8 +812,7 @@ const clickOutsideMenu = (event: Event) => { } .control-pad > button, .clock, -.legacy-menu > summary, -.select-command { +.legacy-menu > summary { box-sizing: border-box; min-height: 34px; border: 0; @@ -822,6 +827,12 @@ const clickOutsideMenu = (event: Event) => { cursor: pointer; list-style: none; } +.select-command { + --legacy-button-height: 34px; + display: grid; + place-items: center; + padding: 4px; +} .clock { background: #345c85; font-variant-numeric: tabular-nums; @@ -1024,9 +1035,6 @@ const clickOutsideMenu = (event: Event) => { grid-template-columns: 5fr 7fr; order: 1; } -.advanced-actions > * { - border-radius: 0 !important; -} .bottom-actions { display: grid; grid-template-columns: repeat(3, 1fr); diff --git a/app/game-frontend/src/components/main/MainMobileBottomBar.vue b/app/game-frontend/src/components/main/MainMobileBottomBar.vue index b754c861..dc492b03 100644 --- a/app/game-frontend/src/components/main/MainMobileBottomBar.vue +++ b/app/game-frontend/src/components/main/MainMobileBottomBar.vue @@ -61,7 +61,7 @@ const onAction = (action: NonNullable) => { >
+
@@ -64,33 +72,21 @@ defineProps<{ gap: 4px; } button { - height: 44px; + --legacy-button-height: 44px; margin: 0; - border: 1px solid #666; - border-radius: 5.25px; - background: #444; - color: #fff; font-size: 14px; - line-height: 18px; - cursor: pointer; } .tournament-page-tabs button { min-width: 72px; padding: 10px 12px; } .tournament-page-tabs button.active { - border-color: #f39c12; - background: #8a5b13; + --legacy-button-bg: #8a5b13; + --legacy-button-border: #704a0f; } .close-button { width: 88px; padding: 10px 16px; - border-color: #375a7f; - background: #375a7f; -} -button:hover, -button:focus { - filter: brightness(1.25); } button:focus-visible { outline: 2px solid #f39c12; diff --git a/app/game-frontend/src/views/AuctionView.vue b/app/game-frontend/src/views/AuctionView.vue index 52d9a5b5..ed31780c 100644 --- a/app/game-frontend/src/views/AuctionView.vue +++ b/app/game-frontend/src/views/AuctionView.vue @@ -197,20 +197,31 @@ onMounted(() => { :class="activeTab === 'resource' ? 'resource-page' : 'unique-page'" >
- - +

{{ activeTab === 'resource' ? '경매장' : '유니크 경매장' }}

+

경매 등록

@@ -331,7 +347,7 @@ onMounted(() => { 매물
+

이전 경매(최근 20건)

@@ -408,7 +424,7 @@ onMounted(() => { 유산포인트 (잔여: {{ formatNumber(uniqueDetail.remainPoint) }}포인트) - + @@ -480,7 +496,9 @@ onMounted(() => {
- +
@@ -530,66 +548,17 @@ onMounted(() => { line-height: 32px; text-align: center; } -.legacy-button { - box-sizing: border-box; - border: solid #3d3d3d; - border-width: 0 1px 4px; - border-radius: 5.25px; - padding: 5.25px 10.5px; - color: #fff; - background: #444; - font: inherit; - font-weight: 700; - line-height: 21px; - cursor: pointer; -} -.legacy-button:hover, -.legacy-button:focus { - border-color: #353535; - background: #393939; -} -.legacy-button:focus-visible { - outline: 2px solid #8ab4f8; - outline-offset: -2px; -} -.legacy-button:active, -.legacy-button[aria-pressed='true'] { - border-color: #303030; - background: #333; -} -.legacy-button:disabled { - cursor: default; - opacity: 0.65; -} .close-button, .reload-button { margin-right: 2px; - border-color: #004f28; - background: #00582c; -} -.close-button:hover, -.close-button:focus, -.reload-button:hover, -.reload-button:focus { - border-color: #004523; - background: #004a25; } .top-back-bar .close-button, .top-back-bar .reload-button { - height: 32px; -} -.tab-button { - border-color: #3d3d3d; - background: #444; + --legacy-button-height: 32px; } .tab-button[aria-pressed='true'] { - border-color: #3d3d3d; - background: #444; -} -.tab-button:hover, -.tab-button:focus { - border-color: #3d3d3d; - background: #444; + --legacy-button-bg: #333; + --legacy-button-border: #303030; } .section-title, .subsection-title, diff --git a/app/game-frontend/src/views/BattleCenterView.vue b/app/game-frontend/src/views/BattleCenterView.vue index eabff0a3..072b9abb 100644 --- a/app/game-frontend/src/views/BattleCenterView.vue +++ b/app/game-frontend/src/views/BattleCenterView.vue @@ -236,9 +236,20 @@ onMounted(() => {
- + - +

감찰부

@@ -305,7 +316,9 @@ onMounted(() => {
- +
@@ -418,17 +431,11 @@ onMounted(() => { text-align: center; } .battle-nav { + --legacy-button-height: 32px; box-sizing: border-box; - height: 32px; margin-right: 2px; - border: 0; - border-radius: 3px; display: grid; place-items: center; - background: #00582c; - color: #fff; - font: inherit; - font-weight: 700; text-decoration: none; } .battle-footer { diff --git a/app/game-frontend/src/views/BettingView.vue b/app/game-frontend/src/views/BettingView.vue index 0d9626ab..9207e61e 100644 --- a/app/game-frontend/src/views/BettingView.vue +++ b/app/game-frontend/src/views/BettingView.vue @@ -130,7 +130,13 @@ const placeBet = async () => {
- + 불러오는 중... {{ message }}
@@ -159,12 +165,7 @@ const placeBet = async () => { @request-bet="openBetDialog" /> - +

베팅하기

@@ -194,9 +195,13 @@ const placeBet = async () => { 금{{ selectedAmount }} - 예상 환수금 {{ selectedExpectedReturn.toLocaleString('ko-KR') }} + 예상 환수금 {{ selectedExpectedReturn.toLocaleString('ko-KR') }} -

현재 배당 기준 예상값이며, 베팅 상황에 따라 최종 배당은 달라질 수 있습니다.

+

+ 현재 배당 기준 예상값이며, 베팅 상황에 따라 최종 배당은 달라질 수 있습니다. +

@@ -289,7 +294,9 @@ const placeBet = async () => {
- + 삼국지 모의전투 HiDCHe / KOEI의 이미지를 사용, 응용하였습니다 / 제작 : HideD(hided62@gmail.com) / Credit @@ -334,8 +341,8 @@ const placeBet = async () => { text-align: left; } .toolbar button { + --legacy-button-height: 44px; min-width: 72px; - height: 44px; padding: 10px 16px; font-size: 14px; } @@ -380,7 +387,7 @@ select { background: #000; color: #fff; } -button { +button:not(.legacy-button) { height: 35.5px; color: #fff; background: #444; @@ -388,16 +395,16 @@ button { border-radius: 5.25px; cursor: pointer; } -button:hover, -button:focus { +button:not(.legacy-button):hover, +button:not(.legacy-button):focus { filter: brightness(1.25); } -button:focus-visible, +button:not(.legacy-button):focus-visible, select:focus-visible { outline: 2px solid #f39c12; outline-offset: 1px; } -button:disabled, +button:not(.legacy-button):disabled, select:disabled { cursor: not-allowed; opacity: 0.5; diff --git a/app/game-frontend/src/views/BoardView.vue b/app/game-frontend/src/views/BoardView.vue index f8f2fde0..d604fad3 100644 --- a/app/game-frontend/src/views/BoardView.vue +++ b/app/game-frontend/src/views/BoardView.vue @@ -126,7 +126,13 @@ onMounted(() => {
- +

{{ title }}

@@ -163,7 +169,7 @@ onMounted(() => {
+
@@ -296,47 +308,9 @@ onMounted(() => { text-align: center; } -.legacy-button { - min-height: 31px; - box-sizing: border-box; - border: 1px solid #3d3d3d; - border-radius: 4px; - padding: 4px 12px; - color: #fff; - background: #444; - font: inherit; - font-weight: 600; - line-height: 1.5; - text-align: center; - text-decoration: none; - cursor: pointer; -} - -.legacy-button:hover { - border-color: #3d3d3d; - background: #444; -} - -.legacy-button:focus-visible { - outline: none; -} - -.legacy-button:active { - border-color: #3d3d3d; - background: #444; -} - .back-button { - height: 32px; + --legacy-button-height: 32px; margin-right: 2px; - border-color: #004f28; - background: #00582c; -} - -.back-button:hover, -.back-button:focus { - border-color: #004523; - background: #004a25; } .board-state { @@ -414,17 +388,10 @@ onMounted(() => { } .article-submit-row .legacy-button { + --legacy-button-height: 35.5px; width: auto; - min-height: 35.5px; margin-right: 10.5px; margin-left: 10.5px; - transition: none; -} - -.article-submit-row .legacy-button:hover, -.article-submit-row .legacy-button:focus, -.article-submit-row .legacy-button:active { - border-color: transparent; } .article-frame { @@ -513,8 +480,8 @@ onMounted(() => { } .submit-comment { + --legacy-button-height: 29.375px; width: 83.333px; - min-height: 29.375px; padding-top: 2px; padding-bottom: 2px; flex: 0 0 auto; @@ -529,9 +496,9 @@ onMounted(() => { } .bottom-bar .back-button { + --legacy-button-height: 35.5px; display: inline-block; width: 71px; - height: 35.5px; margin: 0; padding-right: 6px; padding-left: 6px; diff --git a/app/game-frontend/src/views/ChiefCenterView.vue b/app/game-frontend/src/views/ChiefCenterView.vue index ff8c9bba..a86a9b11 100644 --- a/app/game-frontend/src/views/ChiefCenterView.vue +++ b/app/game-frontend/src/views/ChiefCenterView.vue @@ -318,8 +318,19 @@ const repeatTurns = async (amount: number) => {
- +
@@ -643,19 +656,12 @@ const repeatTurns = async (amount: number) => { text-align: center; } .chief-nav { + --legacy-button-height: 32px; box-sizing: border-box; - height: 32px; margin-right: 2px; - border: 0; - border-radius: 3px; display: grid; place-items: center; - background: #00582c; - color: #fff; - font: inherit; - font-weight: 700; text-decoration: none; - cursor: pointer; } .layout-desktop { display: block; diff --git a/app/game-frontend/src/views/CurrentCityView.vue b/app/game-frontend/src/views/CurrentCityView.vue index f3251a8f..01ea4136 100644 --- a/app/game-frontend/src/views/CurrentCityView.vue +++ b/app/game-frontend/src/views/CurrentCityView.vue @@ -1,6 +1,8 @@