Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

feat(boards): add responsive layout system #2271

Merged
merged 30 commits into from
Feb 23, 2025
Merged

feat(boards): add responsive layout system #2271

merged 30 commits into from
Feb 23, 2025

Conversation

Meierschlumpf
Copy link
Member

@Meierschlumpf Meierschlumpf commented Feb 7, 2025


Homarr

Thank you for your contribution. Please ensure that your pull request meets the following pull request:

  • Builds without warnings or errors (pnpm buid, autofix with pnpm format:fix)
  • Pull request targets dev branch
  • Commits follow the conventional commits guideline
  • No shorthand variable names are used (eg. x, y, i or any abbrevation)

Pending Todos

  • Test mysql migration with some sample data
  • Test imports from oldmarr
  • Issues with hooks (see screenshot below)
  • Add remove button for board layouts (at least one has to exist)
  • Add layouts when creating board (two options, one for sm, md, lg and one for base layout) --> customization can be done later, for now just add one base layout
  • Fix unit tests for board router
  • Add unit tests for save-layouts
  • Rename section / item layouts
  • Remove .json extension for imports
  • Switching from one layout to another breaks positions

image

Closes #2269

@Meierschlumpf Meierschlumpf added the enhancement New feature or request label Feb 7, 2025
@Meierschlumpf Meierschlumpf self-assigned this Feb 7, 2025
@Meierschlumpf Meierschlumpf changed the title Add layouts feat: add responsive board layout system Feb 7, 2025
@Meierschlumpf Meierschlumpf changed the title feat: add responsive board layout system feat(boards): add responsive layout system Feb 7, 2025
Copy link

deepsource-io bot commented Feb 7, 2025

Here's the code health analysis summary for commits c132a07..153ee75. View details on DeepSource ↗.

Analysis Summary

AnalyzerStatusSummaryLink
DeepSource JavaScript LogoJavaScript✅ SuccessView Check ↗

💡 If you’re a repository administrator, you can configure the quality gates from the settings.

Copy link

github-actions bot commented Feb 7, 2025

Coverage Report

Status Category Percentage Covered / Total
🔵 Lines 23.07% 9676 / 41932
🔵 Statements 23.07% 9676 / 41932
🔵 Functions 29.53% 399 / 1351
🔵 Branches 65.2% 1162 / 1782
File Coverage
File Stmts Branches Functions Lines Uncovered Lines
Changed Files
apps/nextjs/src/app/[locale]/boards/_types.ts 0% 0% 0% 0% 1-16
apps/nextjs/src/app/[locale]/boards/(content)/_client.tsx 0% 0% 0% 0% 1-76
apps/nextjs/src/app/[locale]/boards/(content)/_creator.tsx 0% 0% 0% 0% 1-71
apps/nextjs/src/app/[locale]/boards/(content)/_dynamic-client.tsx 0% 0% 0% 0% 1-7
apps/nextjs/src/app/[locale]/boards/[name]/settings/_layout.tsx 0% 0% 0% 0% 1-115
apps/nextjs/src/components/board/items/item-actions.tsx 0% 0% 0% 0% 1-114
apps/nextjs/src/components/board/items/item-content.tsx 0% 0% 0% 0% 1-119
apps/nextjs/src/components/board/items/item-menu.tsx 0% 0% 0% 0% 1-126
apps/nextjs/src/components/board/items/item-move-modal.tsx 0% 0% 0% 0% 1-110
apps/nextjs/src/components/board/items/actions/create-item.ts 93.18% 70% 100% 93.18% 55, 58-59
apps/nextjs/src/components/board/items/actions/duplicate-item.ts 65.67% 66.66% 100% 65.67% 44-63, 81-88
apps/nextjs/src/components/board/items/actions/empty-position.ts 100% 100% 100% 100%
apps/nextjs/src/components/board/items/actions/move-and-resize-item.ts 95.83% 85.71% 100% 95.83% 27
apps/nextjs/src/components/board/items/actions/move-item-to-section.ts 95.83% 85.71% 100% 95.83% 28
apps/nextjs/src/components/board/items/actions/remove-item.ts 100% 100% 100% 100%
apps/nextjs/src/components/board/items/actions/section-elements.ts 100% 100% 100% 100%
apps/nextjs/src/components/board/items/actions/test/mocks/board-mock.ts 100% 100% 100% 100%
apps/nextjs/src/components/board/items/actions/test/mocks/category-section-mock.ts 100% 100% 100% 100%
apps/nextjs/src/components/board/items/actions/test/mocks/dynamic-section-mock.ts 100% 100% 100% 100%
apps/nextjs/src/components/board/items/actions/test/mocks/empty-section-mock.ts 100% 100% 100% 100%
apps/nextjs/src/components/board/items/actions/test/mocks/item-mock.ts 100% 100% 100% 100%
apps/nextjs/src/components/board/items/actions/test/mocks/layout-mock.ts 100% 100% 100% 100%
apps/nextjs/src/components/board/sections/content.tsx 0% 0% 0% 0% 1-85
apps/nextjs/src/components/board/sections/dynamic-section.tsx 0% 0% 0% 0% 1-39
apps/nextjs/src/components/board/sections/empty-section.tsx 0% 0% 0% 0% 1-25
apps/nextjs/src/components/board/sections/section-actions.tsx 0% 0% 0% 0% 1-86
apps/nextjs/src/components/board/sections/section-context.ts 0% 0% 0% 0% 1-23
apps/nextjs/src/components/board/sections/use-section-items.ts 0% 0% 0% 0% 1-53
apps/nextjs/src/components/board/sections/category/category-actions.ts 0% 0% 0% 0% 1-144
apps/nextjs/src/components/board/sections/category/category-menu-actions.tsx 0% 0% 0% 0% 1-144
apps/nextjs/src/components/board/sections/category/actions/remove-category.ts 88.97% 82% 100% 88.97% 16-17, 30-31, 80-88, 134, 149
apps/nextjs/src/components/board/sections/dynamic/dynamic-actions.ts 0% 0% 0% 0% 1-27
apps/nextjs/src/components/board/sections/dynamic/dynamic-menu.tsx 0% 0% 0% 0% 1-45
apps/nextjs/src/components/board/sections/dynamic/actions/add-dynamic-section.ts 0% 0% 0% 0% 1-51
apps/nextjs/src/components/board/sections/dynamic/actions/remove-dynamic-section.ts 0% 100% 100% 0% 7-62
apps/nextjs/src/components/board/sections/gridstack/gridstack.tsx 0% 0% 0% 0% 1-36
apps/nextjs/src/components/board/sections/gridstack/use-gridstack.ts 0% 0% 0% 0% 1-372
packages/api/src/middlewares/integration.ts 13.55% 100% 66.66% 13.55% 32-75, 94-136, 149-174
packages/api/src/router/board.ts 59.55% 82.16% 82.35% 59.55% 46-54, 57-64, 70-95, 171-240, 277-488, 507-511, 524-526, 529-531, 539, 729-923, 944-964, 1079-1094, 1183, 1202, 1213-1228, 1233-1234, 1256-1271, 1276-1277, 1296-1298, 1323-1325, 1416-1417, 1441-1442, 1546-1550, 1606-1607, 1615-1616
packages/api/src/router/app/app-access-control.ts 12.12% 100% 0% 12.12% 10-11, 14-18, 21-45
packages/api/src/router/board/grid-algorithm.ts 98.09% 92.85% 100% 98.09% 152-153
packages/api/src/router/widgets/notebook.ts 46.42% 100% 100% 46.42% 20-36
packages/auth/permissions/integration-query-permissions.ts 97.53% 94.87% 100% 97.53% 52-53
packages/boards/src/context.tsx 14.49% 100% 0% 14.49% 17-54, 57-64, 67-70, 74-81, 84-101, 104, 107-110
packages/db/schema/index.ts 100% 0% 100% 100%
packages/db/schema/mysql.ts 100% 100% 100% 100%
packages/db/schema/sqlite.ts 100% 100% 100% 100%
packages/modals-collection/src/boards/import-board-modal.tsx 0% 0% 0% 0% 1-153
packages/old-import/src/import-error.ts 50% 100% 0% 50% 5-8, 13-14
packages/old-import/src/move-widgets-and-apps-merge.ts 2.27% 100% 0% 2.27% 11-130, 133-206, 209-279, 282-302, 309-333
packages/old-import/src/settings.ts 38.63% 100% 0% 38.63% 27-56
packages/old-import/src/analyse/analyse-oldmarr-import.ts 8.88% 100% 0% 8.88% 11-18, 21-51, 56-64
packages/old-import/src/components/initial-oldmarr-import.tsx 0% 0% 0% 0% 1-94
packages/old-import/src/components/initial/board-selection-card.tsx 0% 0% 0% 0% 1-76
packages/old-import/src/import/input.ts 81.81% 100% 100% 81.81% 13-14
packages/old-import/src/import/collections/board-collection.ts 2.53% 100% 0% 2.53% 18-110
packages/old-import/src/import/collections/integration-collection.ts 5.4% 100% 0% 5.4% 9-52
packages/old-import/src/import/collections/user-collection.ts 4.16% 100% 0% 4.16% 10-66
packages/old-import/src/mappers/map-board.ts 11.76% 100% 0% 11.76% 11-25
packages/old-import/src/mappers/map-breakpoint.ts 9.09% 100% 0% 9.09% 9-18
packages/old-import/src/mappers/map-column-count.ts 8.33% 100% 0% 8.33% 4-14
packages/old-import/src/mappers/map-item.ts 3.26% 100% 0% 3.26% 15-60, 63-114
packages/old-import/src/prepare/prepare-boards.ts 33.33% 100% 0% 33.33% 5-6
packages/old-import/src/prepare/prepare-items.ts 18.18% 100% 0% 18.18% 6-15
packages/old-import/src/prepare/prepare-single.ts 25% 100% 0% 25% 7-13
packages/old-schema/src/index.ts 100% 100% 100% 100%
packages/old-schema/src/tile.ts 82.75% 100% 50% 82.75% 63-72
packages/validation/src/board.ts 100% 50% 100% 100%
packages/validation/src/index.ts 100% 100% 100% 100%
packages/validation/src/shared.ts 100% 100% 100% 100%
Generated in workflow #5242 for commit 153ee75 by the Vitest Coverage Report Action

@Meierschlumpf Meierschlumpf marked this pull request as ready for review February 22, 2025 23:15
@Meierschlumpf Meierschlumpf requested a review from a team as a code owner February 22, 2025 23:15
@Meierschlumpf Meierschlumpf merged commit 7761dc2 into dev Feb 23, 2025
13 checks passed
@Meierschlumpf Meierschlumpf deleted the add-layouts branch February 23, 2025 16:35
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

feat: introduce responsive layout system
2 participants