feat(manufacturers): **Logos for vendors** logo-aware UI and label workflows (core, no bundled assets)#857
Conversation
81b4f74 to
e61f2ad
Compare
e61f2ad to
0419ce3
Compare
eaf2375 to
8d294ac
Compare
|
Are you vibe coding all these changes? Do you test them thoroughly? I don't want to host any companies IP. We cannot have vendor logos in this repository. |
First thing I'm doing here is breaking down the few of PRs I had made to individual and separated changes/features, to not overload review or testing- hence you'll see all the new PRs (draft) all of which need to be retested separately - this logo one included with non direct logo relevant changes moved to other PRs. I had to rely heavily on vibe coding to implement the featues quickly, so testing and review by humans will be essential - and hopefully much easier with the separated PRs. Prior to the PR simplification, I made tons of zip files and AML files, etc - all with various logos and styles. However I certainly didn't check all the corner cases of label sizing, etc - that's a to-do. I agree with your point on the Logo files in the repository - In this implementation, vendor logos can be synced to the user's installation from https://github.com/MarksMakerSpace/filament-profiles upon click, by the user - not in this repository or hosted in this repository - at least that was my intention. |
8d294ac to
58761ad
Compare
58761ad to
4f03ada
Compare
f091b0e to
f4f6564
Compare
There was a problem hiding this comment.
I don't want to host any companies IP. We cannot have vendor logos in this repository.
@Donkie,
Images are now completely out - I realized it was grabbing all the files into this repository too, unintended. That's explicitly removed. And then some to reduce complexity of each change PR. As I noted earlier, I've split apart the large PRs into bite-size chunks and individual improvements.
And went even further with this now Logo specific PR: Splitting into two separate PR with different logo focus:
this PR #857 to build up all the infrastructure for logos. allowing HTML links to image files. and local files. Along with the improvements to print/export of label-aware labels with adjustable details.
then separately PR #872 for the sync with GitHub repository for logos.
I'm still testing many of the PRs and improving the comments/details, including this one. will get them squared away soon.
af29177 to
51204c5
Compare
b555eaa to
9eddfa1
Compare
- Extract _build_search_filters() helper to reduce McCabe complexity - Reduces find() complexity from 13 → ~8 (under 10 limit) - Reduces branch count from 13 → acceptable levels - Resolves Ruff linting errors C901 + PLR0912 - Pure refactoring: behavior unchanged - Also fixes Prettier formatting on filamentSelectModal and qrCodePrintingDialog
0c959fa to
8a294cd
Compare
- Wrap selectUnselectFiltered, handleSelectItem callbacks in useCallback - Wrap handlePageChange, handlePageSizeChange, applySearchFilter in useCallback - Reduces unnecessary re-renders of child components (pagination, checkboxes, buttons) - Stable function references now persist across renders
…ack PR773) - Fetch extra field definitions once at endpoint entry instead of per-request - Eliminates redundant database calls for extra field validation - Applies feedback from PR 773: 'get_extra_fields only needs to be run max at once per call' - Affected endpoints: create/update for filament, spool, and vendor resources - Reduces API layer complexity and improves performance
(cherry picked from commit dc11b7bdae1777a70a68bedfe503f988e96acd13)
…ase URL handling Harden QR export base URL parsing to prevent template injection attacks Per https://github.com/Donkie/Spoolman/wiki/Contribute#style - ESLint (frontend) ✓ Fixed: control character regex - Prettier (frontend) ✓ Fixed: 7 files formatting - Ruff (backend) ✓ - Pre-commit hooks validated ✓
- Wrap selectUnselectFiltered, handleSelectItem callbacks in useCallback - Reduces unnecessary re-renders of table and checkboxes - Consistent with filament selector optimization pattern - Stable function references improve React.memo effectiveness
…export - Add manufacturer logo management (upload, delete, organization) - Integrate logos into label print dialogs (positioning, sizing) - Add vendor logo components and utilities - Support logo source toggle (color/print profile) - Add i18n strings for logo UI elements - Extend vendor database with logo support This commit layers vendor logo features on top of the export workflow. All export functionality is preserved; logos are optional additions to print/export dialogs.
e5873c9 to
f20897d
Compare
- Use single debounced ?search= call, consistent with spool modal and PR846 - Remove 4-field parallel fetch loop, getAPIURL import, allSearchResults state - Fix Ruff violations in vendor.py and vendor_logos.py
6f61439 to
d127692
Compare
- Add useSpoolmanVendorExternalIds and useVendorLogoManifest to otherModels - Declare and forward extraTitleSettings/extraInfoSettings in QRCodePrintingDialog - Add initialSelectedIds, onExport props and Export button to FilamentSelectModal
- qrCodePrintingDialog: 5 spread fixes (identical to PR846) - filamentQrCodePrintingDialog: 4 spread fixes (3 original + titleTemplate) - spoolQrCodePrintingDialog: 4 spread fixes (same as filament) - qrCodeExportDialog: 5 spread fixes (identical to PR860) - spoolSelectModal: selectedSet useMemo + .has() for O(1) checks - exportDialog: move PNG helpers to module scope (same as PR860)
Summary
This PR adds logo-aware manufacturer workflow and logo-aware label behavior
Totally awesome looking logo-filled labels can now be printed/exported
Scope Boundary
Included here:
Not included here:
Stack Notes
#857on branchfeat/manufacturer-logo-upstream-splittargetingmaster#846head4dd7808#860head4caa688#857branch anymore, so the remaining shared fixes were carried forward directly hereScreenshots and Visual Impact
Logos can be uploaded/defined on the manufacturer edit page and Black and White Print Logos can be auto-generated from Color source, or separately uploaded
Improved layout of spool page to incorporate the logos with hyperlink to the filament
Incorporation of separate logo section with individual controls using logo defined in manufacturing page (link or B&W converted print logo)
Separated label layout controls for QR code and information, with again individual controls
###Filtering enabled in Manufacturer section for those with or without logos

Validation Executed
Built and tested
cd client && VITE_APIURL=/api/v1 npm run buildhttp://127.0.0.1:9857Playwright routes exercised in this pass:
/settings/vendor/edit/1/vendor/show/1/spool/show/1at desktop width/spool/show/1at mobile width/filament/show/1/spool/print?spools=1/filament/print?filaments=1/spool/export?spools=1/filament/export?filaments=1/vendorExport download actions exercised in this pass:
Test Checklist
base_urlvalue and shows the saved URL instead of crashingLogo URLandPrint Logo URLfields and previewsShow Manufacturer Logois toggled offHas Logo/No Logofilter path works in the UI and API against the current datasetbase_urlstate fix, and downloads AML/PNG outputbase_urlstate fix, and downloads AML outputTesting exposed issues and resulting fixes incorporated:
base_urlsettings and bad saved local stateNotes
base_urlto confirm the carried-forward compatibility fix on settings, print, and export routes.