1
0
Fork 0
Commit graph

42 commits

Author SHA1 Message Date
a4844efe22 feat(grid): integrate grid view into structure detail page
Replace flat ResourceList with StructureStorageView (grid/list
toggle for structures with dimensions, flat list fallback for
non-grid structures). Apply pluralize to upkeep labels.
2026-07-28 14:03:39 -04:00
9175b103c2 feat(grid): add drag-and-drop grid UI components
GridCell — droppable cell with hover/valid/invalid state
GridItem — draggable item with grip icon, visual feedback
GridToolbar — view toggle, auto-arrange, selected-item actions
InventoryGrid — DndContext wiring, R-key rotation, ResizeObserver
  cell sizing, drag overlay
StructureStorageView — client wrapper with grid/list mode toggle,
  action handlers, resource-to-GridItem mapping
2026-07-28 14:03:34 -04:00
d2222e8701 feat(grid): add grid-aware server actions
addResource now auto-places deposited resources onto the structure
grid (first-fit scan, fills existing stacks first, falls back to
flat-list behavior for non-grid structures).

New server actions:
- placeResourceOnGrid — explicit placement at x,y,rotated
- moveGridItem — move item to new position with optional rotation
- mergeGridStacks — merge two stacks of the same resource
- rotateGridItem — toggle rotation in-place
- removeGridItem — delete a grid entry
- splitGridStack — split a stack into two at an empty spot
- autoArrangeGrid — re-pack all items into grid
2026-07-28 14:03:00 -04:00
7bcbd534e4 feat(grid): add grid utility functions
- GridItem type and GridDimensions helper type
- getItemFootprint: effective size accounting for rotation
- getOccupiedCells: list of "x,y" cell keys
- isValidPlacement: overlap and bounds checking
- findEmptySpot: first-fit scan for available placement
- autoArrangeItems: pack items into grid
- getGridOccupancy: used/total cell counts
2026-07-28 14:02:52 -04:00
d0262baab8 feat(deps): add @dnd-kit/core and @dnd-kit/utilities
Required for drag-and-drop grid item movement in the storage
inventory view.
2026-07-28 14:02:46 -04:00
5982abfb05 feat(ui): add pluralize utility function
Handles irregular plurals, measurement units that stay singular,
and standard English pluralization rules.
2026-07-28 14:02:41 -04:00
159755af8d feat(collections): add grid fields to game-structures and resources schemas
GameStructures:
- Add gridX, gridY, rotated fields to storedResources rows
- Remove beforeValidate hook that merged duplicate resources
- Add read access (was missing)
- Add min: 1 constraint on amount

Resources:
- Add gridWidth, gridHeight, stackable, maxStackSize, rotatable fields
- Add read access (was missing)
- Wrap game-rules afterRead hook in try/catch to handle missing global
2026-07-28 14:02:35 -04:00
275cb49a92 fix: remove console.log from layout causing repeated page requests 2026-07-27 19:42:59 -04:00
866a470750 feat: cap Amount input max to stored amount and remaining capacity
- Withdraw/Transfer tabs: max = currently stored amount of selected resource
- Deposit tab: max = remaining capacity divided by resource massPerUnit
- Amount auto-clamps when resource selection changes
- Show 'Max: X' hint below each amount input
2026-07-27 19:34:47 -04:00
b719f25ff2 feat: use resource unitOfMeasure instead of hardcoded kg, add capacity preview to manage dialog
- Replace hardcoded 'kg' labels with resource.unitOfMeasure in ResourceList
- Rename 'Max Mass' to 'Max Capacity' on structure detail page
- Add dynamic capacity preview bar to ManageStorageDialog deposit/withdraw/transfer tabs
- Add baseline capacity display above tabs in manage dialog
- Clean up unused imports across storage components
2026-07-27 19:27:53 -04:00
12d276d44d feat: implement storage system with capacity tracking and resource management
- Rebuild /logistics/storage overview with capacity bars, filters, and structure cards
- Add /logistics/structures/[id] detail page with resource list, storage rules, upkeep
- Add server actions for deposit, withdraw, and transfer of resources
- Add ManageStorageDialog with deposit/withdraw/transfer tabs
- Add capacity bar component with color-coded utilization
- Add StorageGrid, StructureCard, StorageFilters, ResourceList, StorageRules components
- Add logistics utility functions for mass calculations
- Install shadcn dialog, select, tabs, label components
2026-07-27 19:19:48 -04:00
0280d564f9 feat: add faction ownership to game-structures and relax factions read access
- Allow authenticated users to read factions (was developer-only)
- Add optional faction relationship field to game-structures
- Regenerate payload-types.ts
2026-07-27 19:19:41 -04:00
1eddf741ff feat: add AGENTS.md with technical documentation and configure email sending via Nodemailer 2026-07-27 17:48:43 -04:00
ff1f44832e feat: add approval status field to multiple collections with filtering for developer roles 2026-01-09 02:23:04 -05:00
1d55b50c86 chore: update to 0.1.6 2026-01-09 01:56:32 -05:00
ade5616c68 feat: add migration for experience table and update payload_locked_documents_rels 2026-01-09 01:55:56 -05:00
9cc08c386a chore: update to 0.1.5 2026-01-09 01:52:04 -05:00
2eb38c7a82 feat: enhance form descriptions with dynamic tick calculations and validations
- Replace static descriptions in admin fields with dynamic `TickDurationDescription` components.
- Add minimum and maximum constraints to duration fields in various schemas.
- Update `TickDurationDescription` to use `useField` hook for better form integration.
2026-01-09 01:50:55 -05:00
2f00722f30 chore: clean up unused imports in AppSidebar 2026-01-09 01:26:58 -05:00
d04630ca65 feat: add XP display component and experience collection, integrate user XP in layout 2026-01-09 01:26:40 -05:00
773f6a29c1 chore: update to 0.1.4 2025-12-23 01:03:14 -05:00
9426f12574 feat: add resources to technology schema, improve version display, and introduce migration for resource costs on technologies 2025-12-23 01:01:30 -05:00
d3fbb48422 chore: update to v0.1.3 2025-12-22 16:44:52 -05:00
f5d0ea98eb chore: rename patch script to deploy in package.json 2025-12-22 16:42:06 -05:00
c6fecb54f2 feat: add LAST_UPDATED environment variable, update VersionOverlay to display last updated timestamp, and introduce patch script 2025-12-22 16:41:29 -05:00
0bf874a991 feat: update to v0.1.2 2025-12-22 16:20:20 -05:00
bc4a11120f chore: move deploy script from version to postversion lifecycle 2025-12-22 16:08:34 -05:00
2727580c24 feat: display app version using environment variable and add VersionOverlay component, add migration for new database tables 2025-12-22 16:07:48 -05:00
fc9cbf9bf1 feat: update to v0.1.1 2025-12-22 12:41:12 -05:00
a429cc1c40 chore: add version and preversion scripts 2025-12-22 12:14:19 -05:00
877f8531aa feat: add Hard Resources for system-managed game resources 2025-12-22 12:00:34 -05:00
c1360da9c2 chore: add migration for GameStructures and altered Structure fields 2025-12-19 01:33:49 -05:00
2e00220808 chore: remove redundant access control property 2025-12-19 01:31:00 -05:00
adea2dc996 feat: add ranges to production amounts and frequencies, add dynamic value description to build time 2025-12-19 01:28:40 -05:00
9e4215a84d refactor: rename Page component to DashboardPage, update metadata type, and fix optional chaining in resource mapping 2025-12-17 15:28:43 -05:00
800a863854 chore: add webpack flag to build command 2025-12-17 15:28:22 -05:00
def59ee1fb fix: move Dashboard to frontend, pin dependencies in bun.lock to specific versions for stability 2025-12-17 15:15:07 -05:00
dd6bcd30dc feat: switch to Bun, add fonts and styling, update components and UI, add basic front-end
- Added Google Fonts import for `Geist` and `Geist Mono` to `styles.css`.
- Aligned, cleaned styling variables and properties consistently.
- Updated `seedUsers.ts` to include a developer role.
- Introduced `bun.lock` file for dependency management.
2025-12-16 23:26:52 -05:00
Z8MB1E
9e5a6a2a27 chore: set NextJS build output to "standalone" 2025-12-15 21:34:20 -05:00
Z8MB1E
2e695bd43f feat: application staging deployment (ensure better commits after this) 2025-12-15 01:14:30 -05:00
Z8MB1E
4d639387f4 feat: initial payload scaffolding 2025-10-24 02:07:13 -04:00
Z8MB1E
e4a367489f feat: initial commit 2025-10-15 14:03:31 -04:00