Compare commits

...

1443 Commits
2.0.2 ... 2.2.1

Author SHA1 Message Date
Alejandro
ae7e28b71b Merge pull request #5137 from penpot/niwinz-enhancements-1
 Add limits for invitation creation RPC method
2024-10-03 07:18:18 +02:00
Andrey Antukh
be30174a49 Add limits for team invitations 2024-10-02 16:05:33 +02:00
Alejandro
8373654f80 Merge pull request #5134 from penpot/alotor-hotfix-2.3
Alotor hotfix 2.3
2024-10-02 13:57:05 +02:00
alonso.torres
471c636580 🐛 Fix visual problem with the font-size dropdown in assets 2024-10-02 13:45:50 +02:00
alonso.torres
635c6efe42 🐛 Fix problem with Ctrl+F shortcut on the dashboard 2024-10-02 13:45:30 +02:00
Pablo Alba
0b39318b33 🐛 Fix request dialog is shown in all errors 2024-09-30 09:36:41 +02:00
Alejandro
47cecb2ac4 Merge pull request #5119 from penpot/eva-add-props
  Add shema prop
2024-09-25 11:31:57 +02:00
Eva Marco
5d6ceec803 Add shema prop 2024-09-25 11:07:40 +02:00
Alejandro
16cf16c422 Merge pull request #5114 from penpot/superalex-fix-fetch-profile-exception
🐛 Fix fetch profile exception
2024-09-24 14:24:56 +02:00
Alejandro Alonso
4e1eee197e 🐛 Fix fetch profile exception 2024-09-24 14:13:46 +02:00
Alejandro
91c8af9e38 Merge pull request #5108 from penpot/palba-fix-login-redirect
🐛 Fix bad redirect on new oops page with penpot login
2024-09-24 11:27:04 +02:00
Pablo Alba
58593a9428 🐛 Fix bad redirect on new oops page with penpot login 2024-09-24 10:32:57 +02:00
Eva Marco
17cf57f7ca Merge pull request #5113 from penpot/superalex-fix-show-in-assets-panel
🐛 Fix show in assets panel
2024-09-24 09:38:32 +02:00
Alejandro Alonso
f7cfe36f37 🐛 Fix show in assets panel 2024-09-24 08:49:52 +02:00
Alejandro
c26f909565 Merge pull request #5110 from penpot/eva-fix-code-block-height
🐛 Fix code block height
2024-09-24 06:54:44 +02:00
Eva Marco
6db7fe5f7b 🐛 Fix code block height 2024-09-23 17:03:25 +02:00
Pablo Alba
a207114d95 Merge pull request #5109 from penpot/hiru-fix-swap-inside-group
🐛 Fix error when swapping a copy that is the only child of a group
2024-09-23 15:12:55 +02:00
Eva Marco
b8299a5ea5 🐛 Fix create team without invitations on onboarding 2024-09-23 15:09:43 +02:00
Andrés Moya
1fa461e996 🐛 Fix error when swapping a copy that is the only child of a group 2024-09-23 15:01:01 +02:00
Alejandro
2e3745099b Merge pull request #5107 from penpot/alotor-remove-export-option
🐛 Removed "merge assets" option from export
2024-09-23 13:22:56 +02:00
alonso.torres
6892cffe54 🐛 Removed "merge assets" option from export 2024-09-23 12:13:33 +02:00
Alejandro Alonso
e0034dc205 🐛 Fix onboarding edn urls 2024-09-23 06:30:19 +02:00
Alejandro
bd9eab08b7 Merge pull request #5101 from penpot/palba-migrate-templates-v2
 Update templates links to binary v2
2024-09-23 06:12:15 +02:00
Pablo Alba
b5121657ee Update templates links to binary v2 2024-09-18 16:23:12 +02:00
Aitor Moreno
ca257d1caf Merge pull request #5097 from penpot/eva-fix-arrow-keys-tabs
🐛  Fix arrow key movement on tabs
2024-09-17 17:23:32 +02:00
Aitor Moreno
e164692391 Merge pull request #5098 from penpot/eva-fix-desing-panel
🐛  Fix path side panel options
2024-09-17 17:22:21 +02:00
Eva Marco
b58edea544 🐛 Fix path side panel options 2024-09-17 17:00:40 +02:00
Eva Marco
9a587c91a8 🐛 Fix arrow key movement on tabs 2024-09-17 16:36:44 +02:00
Aitor Moreno
aae1571a5c Merge pull request #5096 from penpot/alotor-bugfixes
Bugfixes
2024-09-17 16:14:59 +02:00
alonso.torres
ebaf30727c 🐛 Fix copy/paste images in Safari 2024-09-17 15:38:18 +02:00
alonso.torres
f5f255e2d5 🐛 Fix problem with comments max length 2024-09-17 14:18:51 +02:00
Alejandro
e65c0d9f48 Merge pull request #5088 from penpot/niwinz-bugfix-2
🐛 Fix issues related to invalid colors inserted on shape shadow
2024-09-17 13:58:43 +02:00
Andrey Antukh
86c5ca4213 🐛 Fix incorrect redirect handling on request-access go-home button 2024-09-16 18:53:56 +02:00
Andrey Antukh
179d534237 🐛 Fix several issues related to invalid colors inserted on shadows 2024-09-16 18:32:40 +02:00
Andrey Antukh
162507264c 🐛 Reexecute file migration 26 again for shapes that has transform prop as nil 2024-09-16 18:32:40 +02:00
Andrey Antukh
7e0a8b6227 Merge pull request #5092 from penpot/palbs-fix-request-acces-dont-go-your-team
🐛 Fix request access to the Team don't go to Your Penpot team
2024-09-16 18:32:19 +02:00
Pablo Alba
475d14edf4 🐛 Fix request access to the Team don't go to Your Penpot team 2024-09-16 14:42:52 +02:00
alonso.torres
979828ffe3 🐛 Fix issue when exporting libraries when merging libraries 2024-09-16 09:08:51 +02:00
alonso.torres
65bb795199 🐛 Fix visual problem with stroke cap menu 2024-09-16 09:07:57 +02:00
Alejandro
a0546b2e63 Merge pull request #5086 from penpot/niwinz-bugfix-1
🐛 Ignore object thumbnail requests if file is already marked as deleted
2024-09-13 12:30:27 +02:00
Andrey Antukh
f291125377 🐛 Add migration for invalid value on layout-wrap-type on shape prop 2024-09-12 21:33:01 +02:00
Andrey Antukh
0ce981a68c 🐛 Add missing ref-id unsassign on srepl helpers for process file 2024-09-12 21:32:34 +02:00
Andrey Antukh
a8814dcaba 🐛 Add missing fields on file-gc libraries fetching sql 2024-09-12 21:07:19 +02:00
Pablo Alba
229eeae6db 🐛 Fix bad redirect on new oops page with social login 2024-09-12 16:35:49 +02:00
Andrey Antukh
d03788af93 🐛 Ignore object thumbnail requests if file is already marked as deleted 2024-09-12 15:23:31 +02:00
Alejandro Alonso
017aad6454 🐛 Fix export failed error when exporting multiple shapes 2024-09-12 12:55:32 +02:00
Alejandro Alonso
767ec37b83 Merge remote-tracking branch 'origin/main' into staging 2024-09-11 12:45:39 +02:00
Alejandro Alonso
89f64e0c49 🐛 Fix challenge redirect with parameters 2024-09-11 12:30:12 +02:00
Alejandro Alonso
d108ad904e Merge remote-tracking branch 'origin/main' into staging 2024-09-11 12:05:21 +02:00
Alejandro Alonso
6564736d3e 🐛 Fix challenge redirect with parameters 2024-09-11 12:03:32 +02:00
Alejandro Alonso
d01cd70c6b Merge remote-tracking branch 'origin/main' into staging 2024-09-11 11:34:04 +02:00
Alejandro
ea7768117c Merge pull request #5082 from penpot/superalex-fix-challenge-redirect-with-parameters
🐛 Fix challenge redirect with parameters
2024-09-11 11:33:45 +02:00
Alejandro Alonso
5bfb39cdf6 🐛 Fix challenge redirect with parameters 2024-09-11 11:23:19 +02:00
Pablo Alba
29f1c2bdad Merge pull request #5080 from penpot/niwinz-oidc-fix-limits-issues
🐛 Fix oidc auth internal limits issue
2024-09-10 16:41:44 +02:00
Andrey Antukh
e79f9ba40f 🐛 Increase token limit 2024-09-10 12:39:54 +02:00
Andrey Antukh
452aabdec6 🐛 Don't send user props on auth token after oidc login 2024-09-10 12:39:54 +02:00
Aitor Moreno
860e32d965 Merge pull request #5070 from penpot/superalex-fix-onboarding
🐛 Fix onboarding questions
2024-09-09 10:19:03 +02:00
Andrey Antukh
495f9dfa84 Merge pull request #5064 from penpot/superalex-release-notes-2.2
 Release notes for 2.2
2024-09-09 09:54:50 +02:00
Alejandro
133ca33cb5 Merge pull request #5076 from penpot/niwinz-exporter-config-parse
🐛 Fix issues on parsing configuration on exporter
2024-09-09 09:54:12 +02:00
Andrey Antukh
1c69a9fd8a 🐛 Fix config parsing on exporter 2024-09-09 09:47:55 +02:00
Andrey Antukh
15faa57e01 🐛 Fix decoding on sm/set schema 2024-09-09 09:46:50 +02:00
Alejandro
f5510234cf Merge pull request #5066 from penpot/eva-fix-frame-row-menu
🐛 Fix guides submenu visualization
2024-09-09 06:49:05 +02:00
Alejandro Alonso
5b0331611d Merge remote-tracking branch 'origin/main' into staging 2024-09-06 13:50:09 +02:00
Alejandro
f8f1c58f61 Merge pull request #5069 from penpot/niwinz-storybook-build-fix
🐛 Fix storybook build related to commonjs to esm module conversion issue
2024-09-06 13:43:04 +02:00
Andrey Antukh
3f34aa92fa Add support for optional human challenge 2024-09-06 13:39:53 +02:00
Alejandro Alonso
c99102e49b 🐛 Fix onboarding questions 2024-09-06 13:18:39 +02:00
Andrey Antukh
d583661e58 🐛 Fix storybook build related to commonjs to esm module conversion issue 2024-09-06 12:31:48 +02:00
Andrey Antukh
ffa326e08f Merge pull request #5067 from penpot/alotor-fix-validation
🐛 Fix problem when dismissing shared library update
2024-09-06 11:31:22 +02:00
alonso.torres
03040ed40b 🐛 Fix problem when dismissing shared library update 2024-09-06 11:02:02 +02:00
Alejandro Alonso
5e89cd1cb3 Release notes for 2.2 2024-09-06 10:49:20 +02:00
Eva Marco
bf202473e9 🐛 Fix guides submenu visualization 2024-09-06 09:47:09 +02:00
Andrey Antukh
886c0c596f Merge pull request #5060 from penpot/alotor-bugfixes
Bugfixes
2024-09-05 15:32:44 +02:00
alonso.torres
b15b394c65 🐛 Fix problem when creating a component instance from grid layout 2024-09-05 15:11:04 +02:00
alonso.torres
caf78a6b4d 🐛 Fix layer panel overflowing 2024-09-05 11:50:16 +02:00
alonso.torres
6a161267ba 🐛 Fix problem with overlay positions in viewer 2024-09-05 10:48:00 +02:00
alonso.torres
a180c33a32 🐛 Fix problem with SVG import 2024-09-05 09:26:22 +02:00
Alejandro
ea8febdb7d Merge pull request #5056 from penpot/niwinz-refactor-recent-colors
♻️ Refactor recent colors and local storage abstraction
2024-09-05 09:07:26 +02:00
Alejandro
f765cc8dbc Merge pull request #5011 from penpot/palba-testab-start-workspace
A/B test start directly at the workspace
2024-09-05 07:05:57 +02:00
Pablo Alba
81b7972347 🎉 Test A/B for start in workspace 2024-09-04 17:19:39 +02:00
Andrey Antukh
1281670c61 Clear storage on user logout 2024-09-04 16:20:00 +02:00
Andrey Antukh
b8c6103858 Add performance enhancements for util/storage abstraction layer 2024-09-04 16:20:00 +02:00
Andrey Antukh
b2c0bed84c Add efficiency improvements to use-resize-hook 2024-09-04 16:20:00 +02:00
Andrey Antukh
9619fcbc1f Make efficiency improvements to use-shared-state hook 2024-09-04 16:20:00 +02:00
Andrey Antukh
e9c55e9eb4 Make recent colors to be stored locally instead of on file 2024-09-04 16:20:00 +02:00
Andrey Antukh
488d034a58 Merge pull request #5055 from penpot/eva-fix-webhook-checkbox
🐛  Fix webhook checkbox position
2024-09-04 14:15:37 +02:00
Eva Marco
8d66275187 🐛 Fix webhook checkbox position 2024-09-04 12:51:30 +02:00
Alejandro
59063e861c Merge pull request #5053 from penpot/niwinz-update-file-refactor
♻️ Refactor file-update for make it more reusable
2024-09-04 12:30:36 +02:00
Andrey Antukh
9da891e9b0 📎 Enable auto-file-snapshot feature scripts/repl 2024-09-04 12:18:31 +02:00
Andrey Antukh
a6de12323e ♻️ Refactor file-update for make it more reusable 2024-09-04 12:18:31 +02:00
Alejandro Alonso
52d099c80e Merge remote-tracking branch 'origin/main' into staging 2024-09-04 12:02:04 +02:00
Alejandro
b2010e5fd8 Merge pull request #5052 from penpot/niwinz-bugfix-srepl-helpers
🐛 Fix issues with srepl helper for profile deletion in bulk
2024-09-04 12:01:55 +02:00
Alejandro
5808bd3743 Merge pull request #5045 from penpot/niwinz-fix-file-gc
🐛 Fix issues on file-gc task
2024-09-04 11:11:13 +02:00
Andrey Antukh
d5f5c440dd 🐛 Fix issues with srepl helper for profile deletion in bulk 2024-09-04 11:09:05 +02:00
Alejandro Alonso
729f679c0f Merge remote-tracking branch 'origin/main' into staging 2024-09-04 08:58:51 +02:00
Alejandro
9f52709a42 Merge pull request #5047 from penpot/niwinz-hotfix-webhooks
🐛 Fix incorrect params handling on webhook processing task
2024-09-04 08:57:53 +02:00
Andrey Antukh
85444f5a47 🐛 Fix incorrect params handling on webhook processing task 2024-09-03 17:19:35 +02:00
Andrey Antukh
50df2279a7 🐛 Make the media cleaning on file-gc task aware of snapshots
It now takes in account the snapshots, and prevents
deletion of media files used in snapshots.
2024-09-03 14:50:17 +02:00
Andrey Antukh
71ba0242c7 🐛 Add missing type decoding on changes schema 2024-09-03 14:42:00 +02:00
Alejandro Alonso
9fb91b3052 Merge remote-tracking branch 'origin/staging' into develop 2024-09-03 13:06:40 +02:00
Alejandro Alonso
689aab32c9 📎 Update changelog 2024-09-03 13:04:04 +02:00
Alejandro Alonso
c642f4afa2 📎 Update version.txt file 2024-09-03 12:52:36 +02:00
Alejandro
a62a083294 Merge pull request #5038 from penpot/palba-add-export-event
🎉 Add export event for telemetry
2024-09-03 12:51:06 +02:00
Pablo Alba
2a13c2ec00 🎉 Add export event for telemetry 2024-09-03 12:03:36 +02:00
Eva Marco
f3525b9ff2 Merge pull request #5044 from penpot/ladybenko-update-changes-ds
📚 Update changelog with the latest DS features
2024-09-03 10:53:00 +02:00
Belén Albeza
d2509f4b97 📚 Update changelog with the latest DS features 2024-09-03 10:38:40 +02:00
Andrey Antukh
6d8c424710 📎 Fix linter issues on ui.auth ns 2024-09-03 10:38:10 +02:00
Andrey Antukh
93e8657f73 Merge remote-tracking branch 'origin/staging' into develop 2024-09-03 08:02:57 +02:00
Alejandro Alonso
91f6c001c0 📚 Update changelog 2024-09-03 06:47:53 +02:00
Andrey Antukh
0dd8300a80 Merge pull request #5037 from penpot/ladybenko-8615-ds-translations
Enable translations for the DS / Storybook
2024-09-02 19:45:09 +02:00
Alejandro
c2b97b13a1 Merge pull request #5042 from penpot/niwinz-update-changelog
📚 Update changelog
2024-09-02 15:22:27 +02:00
Belén Albeza
8feb5dabb0 Use translations in a DS component story 2024-09-02 14:51:41 +02:00
Belén Albeza
8aaa04b1f8 Add English translations to storybook template 2024-09-02 14:51:41 +02:00
Andrey Antukh
a28117b301 📚 Add missing backend enhancements on the changelog 2024-09-02 13:21:02 +02:00
Andrey Antukh
0117a4767d 📎 Rename file-snapshot to auto-file-snapshot 2024-09-02 11:52:19 +02:00
Andrey Antukh
bf60bf1848 Merge pull request #5033 from penpot/superalex-revert-test-default-theme
Revert "🎉 Test A/B for starting with light theme"
2024-08-29 11:42:04 +02:00
Andrey Antukh
c581395df2 Merge pull request #5034 from penpot/superalex-track-copy-shared-link-event
 Track copy shared link event
2024-08-29 10:26:34 +02:00
Alejandro Alonso
8a44fb689a 🐛 Fix create share link name 2024-08-29 10:25:08 +02:00
Alejandro Alonso
9fd36526ef Track copy shared link event 2024-08-29 10:25:08 +02:00
Alejandro Alonso
78f4d9cc5d 🎉 Revert test A/B for starting with light theme
This reverts commit b0af94415f.
2024-08-28 13:00:43 +02:00
Alejandro
bd2a3e197a Merge pull request #5032 from penpot/niwinz-backports-1
🐛 Backport several bugfixes from develop
2024-08-28 12:49:16 +02:00
Alejandro
d703205921 Merge pull request #5028 from penpot/niwinz-path-changes
🐛 Add missing safechecks and schema validations
2024-08-28 12:41:18 +02:00
Alejandro
1e73bec2b9 Merge pull request #5031 from penpot/niwinz-fire-version-txt
🔥 Remove the usage of version.txt
2024-08-28 12:30:57 +02:00
Andrey Antukh
1abbeb0273 Merge pull request #5015 from penpot/yamila-moreno-patch-1
Update manage.sh
2024-08-28 11:15:07 +02:00
Andrey Antukh
d25424d325 🔥 Remove the usage of version.txt 2024-08-28 11:14:28 +02:00
Andrey Antukh
cc98ac5853 🐛 Fix json encoding on zip encoding decoding 2024-08-28 10:43:47 +02:00
Andrey Antukh
05750c3b38 🐛 Add schema validation for color changes 2024-08-28 10:43:47 +02:00
Andrey Antukh
3ddecef5a7 Ensure plain map on path params in several functions 2024-08-28 10:31:22 +02:00
Andrey Antukh
7fd96a0533 🎉 Backport app.common.json namespace from develop 2024-08-28 10:30:11 +02:00
Andrey Antukh
19d6f4381a Merge pull request #5023 from penpot/eva-add-tooltips-to-typography
🐛 Add missing tooltips to typography options
2024-08-27 17:54:41 +02:00
Andrey Antukh
25e9129a8e 🔥 Remove unused and deprecated helpers from app.util.object ns 2024-08-27 16:44:14 +02:00
Andrey Antukh
569674452a Add label and id support for debug snapshot helpers 2024-08-27 15:43:31 +02:00
Andrey Antukh
2643dae0a7 🐛 Fix json encoding on zip encoding decoding 2024-08-27 15:43:31 +02:00
Andrey Antukh
1f53e48032 🐛 Add schema validation for color changes 2024-08-27 10:48:38 +02:00
Andrey Antukh
ef3a47b492 Add efficiency changes to get-segments helper 2024-08-27 10:48:38 +02:00
Andrey Antukh
f302c724c4 Add efficiency changes on make-curve-point helper 2024-08-27 10:48:37 +02:00
Andrey Antukh
4ce654511b Ensure plain map on path params in several functions 2024-08-27 10:48:37 +02:00
Andrey Antukh
2f68310a7c 📎 Add some fixmes for future path changes 2024-08-27 10:48:37 +02:00
Alejandro
67cd855e97 Merge pull request #5027 from penpot/niwinz-backend-improvements
 Add efficiency improvements to xlog task
2024-08-27 09:59:59 +02:00
Andrey Antukh
ceaafdbb1c Add offload mechanism for file snapshots 2024-08-26 13:52:42 +02:00
Andrey Antukh
8dea5d5158 ♻️ Make file-xlog-gc task more scalable 2024-08-26 11:15:59 +02:00
Alejandro
7ea5c79393 Merge pull request #5019 from penpot/niwinz-static-error-duplication
 Add improvements on how UI (React) errors are handled
2024-08-26 09:26:28 +02:00
Andrey Antukh
215148ca81 Add better fillfactor setting for storage_object and task tables 2024-08-23 15:09:58 +02:00
Eva Marco
897960194e 🐛 Add missing tooltips to typography options 2024-08-23 13:42:33 +02:00
Alejandro
5d97f4b924 Merge pull request #5020 from penpot/eva-fix-color-picker
🐛  Fix color picker
2024-08-23 12:37:25 +02:00
Alejandro
e7b663749a Merge pull request #5021 from penpot/eva-fix-design-tab-layout
🐛 Fix design tab layout after new tab component added
2024-08-23 12:25:38 +02:00
Eva Marco
aa5999b2e0 🐛 Fix design tab layout after new tab component added 2024-08-23 11:59:23 +02:00
Alejandro
736d75a93c Merge pull request #5009 from penpot/niwinz-json-decoder-2
🎉 Add `:assign` operation as alternative to `:set`
2024-08-23 11:53:07 +02:00
Eva Marco
c81a17ada5 🐛 Fix color picker 2024-08-23 11:52:05 +02:00
Andrey Antukh
401a28f317 ⬆️ Update rumext to v2.14
Adds some improvements on compiler
2024-08-23 11:21:54 +02:00
Andrey Antukh
f16caa2b98 💄 Add cosmetic changes on sidebar/options ns 2024-08-23 11:21:54 +02:00
Andrey Antukh
868af29d14 💄 Add some cosmetic changes to sidebar ns 2024-08-23 11:21:54 +02:00
Andrey Antukh
a091c9c910 ♻️ Refactor how UI error reporting is handled 2024-08-23 11:21:54 +02:00
Anonymous
1d1d4d9371 🌐 Add translations for: Serbian.
Currently translated at 96.0% (1395 of 1453 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/sr/
2024-08-23 11:16:13 +02:00
Anonymous
d578659b21 🌐 Add translations for: Dutch.
Currently translated at 96.2% (1399 of 1453 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/nl/
2024-08-23 11:16:13 +02:00
Anonymous
2be9cebb0e 🌐 Add translations for: Portuguese (Portugal).
Currently translated at 96.2% (1399 of 1453 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/pt_PT/
2024-08-23 11:16:13 +02:00
Anonymous
982b900066 🌐 Add translations for: Hebrew.
Currently translated at 96.2% (1399 of 1453 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/he/
2024-08-23 11:16:12 +02:00
Anonymous
4c1bc7c3c1 🌐 Add translations for: German.
Currently translated at 96.2% (1399 of 1453 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/de/
2024-08-23 11:16:12 +02:00
Anonymous
fb09959459 🌐 Add translations for: Turkish.
Currently translated at 96.2% (1399 of 1453 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/tr/
2024-08-23 11:16:12 +02:00
Anonymous
5601ed7071 🌐 Add translations for: Russian.
Currently translated at 96.1% (1397 of 1453 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/ru/
2024-08-23 11:16:12 +02:00
Anonymous
5ab282c344 🌐 Add translations for: French.
Currently translated at 96.2% (1398 of 1453 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/fr/
2024-08-23 11:16:12 +02:00
Anonymous
5eb4b28834 🌐 Add translations for: Spanish.
Currently translated at 99.1% (1440 of 1453 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/es/
2024-08-23 11:16:11 +02:00
Andrey Antukh
4cdea36b7c 📎 Rehash & sort all translations 2024-08-23 11:09:45 +02:00
Andrey Antukh
f2c1d4d83d Merge branch 'translations' into develop 2024-08-23 11:04:10 +02:00
Andrey Antukh
9dd0cd57ce Merge remote-tracking branch 'weblate/develop' into translations 2024-08-23 11:03:39 +02:00
Andrey Antukh
3026bd8aaf Merge remote-tracking branch 'origin/staging' into develop 2024-08-23 10:59:14 +02:00
Andrey Antukh
2ec27de353 🎉 Add :assing operation as altenative to :set 2024-08-23 10:55:10 +02:00
Andrey Antukh
f73e5446ab Merge pull request #5016 from penpot/superalex-bug-render-texts-without-position-data
🐛 Fix render of some texts without position data
2024-08-22 15:43:50 +02:00
Alejandro Alonso
df255b5a6f 🐛 Fix render of some texts without position data 2024-08-22 15:24:13 +02:00
Andrey Antukh
9a3c953f0f Merge pull request #5014 from penpot/juanfran-update-plugins-runtime
⬆️ Update plugins runtime
2024-08-22 12:47:02 +02:00
Yamila Moreno
02c031a0ef 📎 Delete unnecessary option in manage.sh script
Delete `-x` option as it gives an annoying output when we're not debugging.
2024-08-22 12:45:18 +02:00
Juanfran
a5114369ba ⬆️ Update plugins runtime 2024-08-22 12:13:20 +02:00
Andrey Antukh
4765685440 Merge pull request #5010 from penpot/eva-replace-tabs-component
♻️ Replace tabs component
2024-08-22 10:31:22 +02:00
Eva Marco
3f3c3a3df4 🐛 Fix labelled by on tab-panel component 2024-08-21 13:39:16 +02:00
Alejandro
baa52d432f Merge pull request #5003 from penpot/niwinz-json-decoder
🎉 Add json encode/decode mechanism for schemas
2024-08-21 12:48:41 +02:00
Andrey Antukh
89562d0231 Add schema validation for tabs 2024-08-21 11:55:12 +02:00
Eva Marco
3df9c88bb7 ♻️ Replace layer tabs component with the new tab switcher component 2024-08-21 11:54:39 +02:00
Andrey Antukh
cacee40d11 🎉 Add proper schema encoding/decoding mechanism
this allows almost all api operations to success usin application/json
encoding with the exception of the update-file, which we need to
approach a bit differently;

the reason update-file is different, is because the operations vector
is right now defined without the context of shape type, so we are just
unable to properly parse the value to correct type using the schema
decoding mechanism
2024-08-21 11:27:36 +02:00
Eva Marco
1782837a38 ♻️ Replace colorpicker modal tab component 2024-08-20 14:01:29 +02:00
Alejandro
de05521b57 Merge pull request #5001 from penpot/superalex-fix-deleted-fonts
🐛 Fix deleted fonts on file load
2024-08-20 13:13:48 +02:00
Alejandro Alonso
c86afca1d0 🐛 Fix deleted fonts on file load 2024-08-20 13:00:18 +02:00
Andrey Antukh
5617ca24b8 Merge pull request #5008 from penpot/superalex-improve-disabled-registry-flows
 Improve disabled registry flows
2024-08-20 10:11:20 +02:00
Eva Marco
c0cd980f5f ♻️ Replace libraries modal tab component 2024-08-20 09:55:18 +02:00
Alejandro Alonso
cd51f2f652 Improve disabled registry flows 2024-08-20 08:20:46 +02:00
Eva Marco
2f99d17885 ♻️ Replace tab switcher on design tab 2024-08-19 16:26:17 +02:00
Eva Marco
63ffa704f5 ♻️ Replace tab switcher on viewer 2024-08-19 16:26:10 +02:00
Eva Marco
129b7afda9 ♻️ Remove components preview 2024-08-19 16:25:46 +02:00
Pablo Alba
00bb988ecc Merge pull request #5007 from penpot/superalex-a-b-remove-testing-signup-01
 Add a/b remove testing for signup image
2024-08-19 10:49:32 +02:00
Alejandro Alonso
5efc56eb5a Revert " Add a/b testing for signup image"
This reverts commit 5ac6f04857.
2024-08-19 10:22:01 +02:00
Alejandro
0ccae600bc Merge pull request #5000 from penpot/palba-default-light
🎉 Test A/B for starting with light theme
2024-08-19 08:57:10 +02:00
Pablo Alba
b0af94415f 🎉 Test A/B for starting with light theme 2024-08-19 08:20:31 +02:00
Црнобог
1c09670e3c 🌐 Add translations for: Serbian.
Currently translated at 98.6% (1389 of 1408 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/sr/
2024-08-17 13:09:32 +02:00
Andrey Antukh
0db1eed87f Improve word-string schema generator
make it to generate a more readable strings
2024-08-16 14:43:06 +02:00
Andrey Antukh
db52d98595 📎 Update user ns on common and backend 2024-08-16 14:43:06 +02:00
Andrey Antukh
e46b5b3f57 🎉 Add json module to common 2024-08-16 14:43:06 +02:00
Alejandro
d1d3b4353a Merge pull request #4987 from penpot/eva-add-selection-colors-to-ds
  Add selection colors to ds
2024-08-16 07:59:18 +02:00
Црнобог
3c0944ebfc 🌐 Add translations for: Serbian.
Currently translated at 98.5% (1388 of 1408 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/sr/
2024-08-15 17:09:28 +02:00
Црнобог
a2725ed8fe 🌐 Add translations for: Russian.
Currently translated at 99.6% (1403 of 1408 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/ru/
2024-08-15 17:09:18 +02:00
Alejandro
84bfef9938 Merge pull request #4920 from penpot/palba-request-access
Oops page and Request access
2024-08-14 15:53:45 +02:00
Pablo Alba
6169f5c2e8 🎉 New oops page with login and request access 2024-08-14 15:32:04 +02:00
Andrey Antukh
fc14871d01 Merge pull request #4993 from penpot/eva-fix-fill-menu
🐛 Fix collapsing fill menu
2024-08-14 13:09:03 +02:00
Andrey Antukh
bcfa1d4394 Merge pull request #4996 from penpot/eltociear-patch-2
🐛 Update time.cljc
2024-08-14 13:08:40 +02:00
Ikko Eltociear Ashimine
2361b2b63a 🐛 Update time.cljc
prefered -> preferred
2024-08-14 12:58:44 +02:00
Andrey Antukh
380ead2ad6 Merge pull request #4994 from penpot/superalex-make-explicit-test-openldap-devenv-docker-ulimits
 Make explicit test-openldap devenv docker ulimits
2024-08-14 12:57:09 +02:00
Alejandro Alonso
3df45d697d Make explicit test-openldap devenv docker ulimits 2024-08-14 11:07:00 +02:00
Alejandro
efb70f0b97 Merge pull request #4985 from penpot/niwinz-hotfix-2
🐛 Disable ipv6 from docker nginx resolver.
2024-08-14 10:50:26 +02:00
Alejandro
d9a941cb32 Merge pull request #4992 from penpot/juanfran-invalid-content-path-arguments
🐛 Fix typo in command parsing (paras to params)
2024-08-14 09:40:37 +02:00
Eva Marco
f43ca1869b 🐛 Fix collapsing fill menu 2024-08-14 09:24:26 +02:00
Juanfran
a34b06cfb4 🐛 Fix typo in command parsing (paras to params)
Signed-off-by: Juanfran <juanfran.ag@gmail.com>
2024-08-14 09:23:23 +02:00
Madalena Melo
f5b910d391 🌐 Added translation for: Serbian. 2024-08-14 09:06:16 +02:00
Alejandro
924c1d60f9 Merge pull request #4990 from penpot/niwinz-hotfix-5
🐛 Update storage specs
2024-08-13 12:47:24 +02:00
Andrey Antukh
6b80f19e5f 🐛 Update storage specs 2024-08-13 12:21:16 +02:00
Eva Marco
b57e68f4b6 Add selection colors to ds 2024-08-13 12:06:46 +02:00
Alejandro
000d2c3935 Merge pull request #4989 from penpot/niwinz-hotfix-3
🐛 Backport  storage changes from develop
2024-08-13 11:26:49 +02:00
Alejandro
d2311f066a Merge pull request #4988 from penpot/niwinz-fix-notifications
🐛 Fix incorrect params for notifications
2024-08-13 11:17:58 +02:00
Andrey Antukh
91435bf372 🐛 Backport storage backend naming changes from develop
for properly handle backward comaptibility when two
versions are running over a single database
2024-08-13 11:14:38 +02:00
Andrey Antukh
aa39de4ea8 🐛 Fix incorrect params for notifications 2024-08-13 11:04:26 +02:00
Eva Marco
215f6fc0ab Merge pull request #4973 from penpot/ladybenko-8255-focus-mode
🐛 Fix layer sidebar in focus mode for long names
2024-08-13 10:34:41 +02:00
Alejandro
ea5c22c244 Merge pull request #4983 from penpot/niwinz-backports-1
🐛 Backport bugfixes from develop
2024-08-13 08:25:10 +02:00
Belén Albeza
fc333ae098 Merge pull request #4941 from penpot/eva-tabs-component-ds
  Add tabs component to DS
2024-08-12 17:46:59 +02:00
Belén Albeza
d3e891eec3 Enable focusing on tab-switcher* panel 2024-08-12 17:35:28 +02:00
Eva Marco
66d30e35c7 Add tab switcher component documentation 2024-08-12 17:35:28 +02:00
Eva Marco
b8693c3f85 Add tab component to the DS 2024-08-12 17:35:26 +02:00
Eva Marco
4b2742efca Merge pull request #4972 from penpot/ladybenko-7887-toast
Implement `toast*` component
2024-08-12 16:28:57 +02:00
Andrey Antukh
e07c1bba7a 🐛 Disable ipv6 from docker nginx resolver 2024-08-12 16:22:19 +02:00
Andrey Antukh
ec56a4149b 🐛 Fix unhandled exception on try to reuse registration token 2024-08-12 12:59:18 +02:00
Andrey Antukh
314742a563 Add :params prop to :not-found exception 2024-08-12 12:59:18 +02:00
Andrey Antukh
38c9e3e7cc 🐛 Fix error handling issue on login with oidc
happens when no oidc backend is configured on backend
2024-08-12 12:59:18 +02:00
Andrey Antukh
c1435fba95 Merge pull request #4980 from rasom/fix-link-contributing-guide
📚 Fix dead link in contributing guide
2024-08-12 12:25:23 +02:00
Alejandro
b13148265e Merge pull request #4982 from penpot/niwinz-bugfix-3
🐛 Bugfixes
2024-08-12 12:12:15 +02:00
Andrey Antukh
c0174ab501 🐛 Fix unhandled exception on try to reuse registration token 2024-08-12 11:55:19 +02:00
Andrey Antukh
77c45ed109 Add better error reporting on offload-file-data task 2024-08-12 11:55:19 +02:00
Andrey Antukh
7df68bb8bd Add :params prop to :not-found exception 2024-08-12 11:55:19 +02:00
Andrey Antukh
ab461ba560 🐛 Launch offload only if file-gc has processed the file 2024-08-12 11:55:19 +02:00
Alejandro
280252d40e Merge pull request #4958 from penpot/niwinz-fdata-storage-offload
🎉 Add file-data offload mechanism
2024-08-12 10:59:29 +02:00
Alhassan Atama
09b6989491 🌐 Add translations for: Igbo.
Currently translated at 37.1% (523 of 1408 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/ig/
2024-08-11 20:09:13 +00:00
Alhassan Atama
f96bbb38b0 🌐 Add translations for: Hausa.
Currently translated at 89.9% (1267 of 1408 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/ha/
2024-08-11 20:09:13 +00:00
Roman Volosovskyi
f0e3dc2f0e 📚 Fix dead link in contributing guide 2024-08-11 22:03:41 +02:00
Andrey Antukh
d2937a76d9 🐛 Fix error handling issue on login with oidc
happens when no oidc backend is configured on backend
2024-08-09 14:28:18 +02:00
Andrey Antukh
3219c150d4 Add better internal fillfactor setting for file table
Increasing the change for HOT updates on db for this heavy-update
table
2024-08-09 14:28:18 +02:00
Andrey Antukh
ba167f256b Add performance enhancements on telemetry related queries 2024-08-09 14:28:18 +02:00
Andrey Antukh
0e92bcc0de 🎉 Add file-data offload mechanism 2024-08-09 14:28:18 +02:00
Andrey Antukh
f6bfe3931c Add performance enhacements to storage/gc-touched task 2024-08-09 14:13:33 +02:00
Andrey Antukh
253b9e5bd8 Split file-gc task in two separated tasks
Add a new file-gc-scheduler task for analizing all files for
elegibility and leave file-gc task with the responsability to
performn the GC operation.
2024-08-09 14:13:33 +02:00
Belén Albeza
604f80de20 📚 Add documentation for toast* 2024-08-09 13:07:55 +02:00
Belén Albeza
0aa8f7bfc6 🐛 Fix layer sidebar in focus mode for long names 2024-08-09 12:54:42 +02:00
Dário
4cc2c736e9 🌐 Add translations for: Portuguese (Portugal).
Currently translated at 100.0% (1408 of 1408 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/pt_PT/
2024-08-09 04:09:16 +02:00
Belén Albeza
9455b56c07 Implement toast* component 2024-08-08 15:46:57 +02:00
Andrey Antukh
d6f528acd2 Merge pull request #4955 from penpot/eva-bugfixing-1
🐛 Fix several bugs
2024-08-08 11:38:18 +02:00
Alejandro Alonso
9344fb958a Merge remote-tracking branch 'origin/staging' into develop 2024-08-08 07:43:10 +02:00
Andrey Antukh
2533d0ebc0 Add naming consistency changes for file_data_fragment table 2024-08-08 07:42:17 +02:00
Alejandro
6ee9025f13 Merge pull request #4971 from penpot/niwinz-fdata-storage-offload-2
 Add naming consistency changes for file_data_fragment table
2024-08-08 07:41:54 +02:00
Alejandro
3a2e868d80 Merge pull request #4915 from penpot/niwinz-mini-refactor-notifications
♻️ Mini refactor of notification components locations
2024-08-08 07:18:13 +02:00
Andrey Antukh
86a732600b Add naming consistency changes for file_data_fragment table 2024-08-07 16:34:39 +02:00
Andrey Antukh
22f3dba842 💄 Update run-store helper 2024-08-07 16:07:59 +02:00
Andrey Antukh
bde1cd3f5f 🐛 Fix unexpected exception on frontend test
caused by unexpected return nil on a merge-map
2024-08-07 16:07:59 +02:00
Andrey Antukh
f187012469 ♻️ Refactor naming and location of flash notifications 2024-08-07 15:04:52 +02:00
Andrey Antukh
a1c78683f5 📎 Update version.txt file 2024-08-07 10:57:51 +02:00
Belén Albeza
3917215952 Merge pull request #4969 from penpot/superalex-fix-storybook-css-path
🐛 Fix storybook css path
2024-08-07 09:31:00 +02:00
Alejandro Alonso
5f0c036ad5 🐛 Fix storybook css path 2024-08-07 06:46:06 +02:00
Andrey Antukh
f0342f25ea Merge pull request #4967 from penpot/superalex-fix-missing-env-variable-for-building
🐛 Fix missing storybook env variable for building
2024-08-06 17:32:22 +02:00
Alejandro Alonso
f5a8c806d9 🐛 Fix missing storybook env variable for building 2024-08-06 16:34:09 +02:00
Alejandro
f8cbe1dfbf Merge pull request #4965 from penpot/niwinz-storybook-fixes
⬆️ Update beicon version to v2.2
2024-08-06 12:52:58 +02:00
Andrey Antukh
c6c9e7d179 ⬆️ Update beicon version to v2.2
Fixes the esm build compatibility issues
2024-08-06 12:29:18 +02:00
Alejandro
4fe77ca386 Merge pull request #4963 from penpot/niwinz-oidc-fixes-2
🐛 Fix OIDC issues and regressions
2024-08-06 12:02:02 +02:00
Andrey Antukh
ea7ad2aaa0 Add flag oidc-registration for switch on/off registration with oidc 2024-08-06 11:51:26 +02:00
Andrey Antukh
36ac81bb43 Merge pull request #4964 from penpot/superalex-fix-storybook-build
🐛 Fix storybook build
2024-08-06 10:47:54 +02:00
Alejandro Alonso
1515498a23 🐛 Fix storybook build 2024-08-06 10:46:37 +02:00
Andrey Antukh
d0059cbe29 Merge pull request #4952 from penpot/ladybenko-8439-storybook-build
Storybook build
2024-08-06 10:25:18 +02:00
Julian Schacher
0162451205 Revert "🐛 Set proper default tenant on exporter"
This reverts commit 86b2ce4dab.
2024-08-06 10:15:21 +02:00
sangpil hwang
34cf6e9e58 🌐 Add translations for: Korean.
Currently translated at 15.8% (223 of 1408 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/ko/
2024-08-05 21:09:25 +02:00
Nima K
05e283baec 🌐 Add translations for: Persian.
Currently translated at 50.0% (705 of 1408 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/fa/
2024-08-05 21:09:24 +02:00
Belén Albeza
457da6f23e Append timestamp to CSS import in storybook 2024-08-05 17:39:57 +02:00
Andrey Antukh
0f16f65d30 🔧 Update script names and conditionally build storybook 2024-08-05 17:39:37 +02:00
Andrey Antukh
82ad240053 Merge pull request #4960 from penpot/superalex-fix-custom-smtp-port-with-ssl-enabled
🐛 Fix custom smtp port with ssl enabled
2024-08-05 13:01:17 +02:00
Alejandro Alonso
aa21430a5c 🐛 Fix custom smtp port with ssl enabled 2024-08-05 12:45:05 +02:00
Andrey Antukh
aa4368f97f Merge pull request #4959 from penpot/superalex-fix-user-language-validator
🐛 Fix user language validator
2024-08-05 12:35:32 +02:00
Alejandro Alonso
8eddcd64f1 🐛 Fix user language validator 2024-08-05 11:05:56 +02:00
Eva Marco
1c2b6f5ab5 Merge pull request #4938 from penpot/ladybenko-7879-ds-input
🎉 Implement input* component
2024-08-05 08:58:53 +02:00
Eva Marco
f011d94339 🐛 Fix error on padding input props 2024-08-02 14:14:51 +02:00
Eva Marco
d527bbd8b5 🐛 Fix fill collapsed options 2024-08-02 11:12:28 +02:00
Belén Albeza
2015c484d0 📚 Add Input component documentation 2024-08-02 11:08:20 +02:00
Belén Albeza
480d5ba7c3 🎉 Implement input* component 2024-08-02 11:08:20 +02:00
Eva Marco
6b3bfc85b3 🐛 Fix scroll on color picker modal 2024-08-02 09:30:42 +02:00
Belén Albeza
2b2bc73564 🔧 Update build script to include storybook 2024-08-01 16:11:01 +02:00
Belén Albeza
7cdfd5a6d3 Watch css assets specifically for storybook 2024-08-01 15:31:23 +02:00
Belén Albeza
8bcc2a4932 Compile storybook target in release and a separate DS stylesheet 2024-08-01 15:29:02 +02:00
Belén Albeza
deef8abca5 🔧 Enable storybook to be served from a subdir 2024-08-01 15:29:02 +02:00
Pablo Alba
fcf9444b1d Merge pull request #4948 from penpot/superalex-a-b-testing-signup-01
 Add a/b testing for signup image
2024-08-01 10:28:43 +02:00
Belén Albeza
f683d65990 Merge pull request #4949 from penpot/niwinz-update-beicon
⬆️ Update dependencies
2024-07-31 16:54:04 +02:00
Andrey Antukh
93ec352f4a ⬆️ Update shadown-cljs and beicon dependency
Fixes compatibility issues between shadow-cljs :esm build and beicon
library.
2024-07-31 16:30:22 +02:00
Andrey Antukh
e0b009c538 ⬆️ Update yarn version to 4.3.1 2024-07-31 16:30:22 +02:00
Alejandro Alonso
5ac6f04857 Add a/b testing for signup image 2024-07-31 13:04:12 +02:00
Andrey Antukh
5c61d874be Merge remote-tracking branch 'origin/develop' into develop 2024-07-31 12:47:05 +02:00
Andrey Antukh
5cf64c1440 Merge remote-tracking branch 'origin/staging' into develop 2024-07-31 12:46:47 +02:00
Alejandro
b4d91b5a48 Merge pull request #4937 from penpot/niwinz-fix-email-complains-handling
 Add improvements to internal sns handler
2024-07-31 12:18:01 +02:00
Andrey Antukh
52425a993a 🐛 Check complaints reports in the same way as bounces are checked 2024-07-31 12:02:42 +02:00
Alejandro
ed91c7ca32 Merge pull request #4689 from penpot/niwinz-devenv-upgrade
⬆️ Upgrade devenv linux distribution version
2024-07-31 10:46:27 +02:00
Alejandro
e72e812166 Merge pull request #4943 from penpot/niwinz-temporal-log
 Add temporal log entry for profile insert conflict
2024-07-31 10:45:48 +02:00
Andrey Antukh
fdbec9917c Merge pull request #4946 from june128/fix-stuck-progress-bar
Revert "🐛 Set proper default tenant on exporter"
2024-07-31 10:15:28 +02:00
Pablo Alba
65a00aa13f Merge pull request #4931 from penpot/hiru-fix-touched-detach
🐛 Fix touched groups when detaching with nested copies
2024-07-31 09:46:16 +02:00
Julian Schacher
5ae28da709 Revert "🐛 Set proper default tenant on exporter"
This reverts commit 86b2ce4dab.
2024-07-31 00:32:48 +02:00
Andrey Antukh
acc0623219 Add temporal log entry for profile insert conflict 2024-07-30 16:46:38 +02:00
Andrés Moya
990a948bcc 🐛 Fix touched groups when detaching with nested copies 2024-07-30 14:28:37 +02:00
Belén Albeza
dba94237dc Merge pull request #4912 from penpot/eva-remove-old-tokens
♻️ Remove unused tokens
2024-07-30 12:03:07 +02:00
Alejandro
802846a838 Merge pull request #4929 from penpot/niwinz-snapshoting-improvements
 Improve file snapshoting mechanism
2024-07-30 08:15:09 +02:00
Andrey Antukh
e0f2c4e0aa Add the ability to pass body to a log entry 2024-07-29 16:16:39 +02:00
Andrey Antukh
c2aa4f4893 Merge pull request #4936 from n-stha/n-stha-fix-spelling
📎 Correct a spelling in onboarding.edn
2024-07-29 15:23:18 +02:00
n-stha
25c875dc55 📎 Correct a spelling in onboarding.edn 2024-07-29 18:52:40 +05:45
Eva Marco
2c5289d338 ♻️ Remove duplicated color tokens 2024-07-29 11:05:14 +02:00
Alejandro
00c5d58203 Merge pull request #4903 from penpot/palba-bugfixing-010
🐛 Fix Components are not dragged from the group to the assets tab
2024-07-29 10:34:28 +02:00
Andrey Antukh
5cf54c6384 Improve file snapshoting mechanism 2024-07-29 10:19:34 +02:00
Eva Marco
7c75af83b3 Merge pull request #4904 from penpot/eva-substitude-loader-component
♻️  Replacing the old Pencil loader with the new Loader component
2024-07-29 10:08:08 +02:00
Belén Albeza
39b2c1722a ♻️ Refactor loader* component props & usage 2024-07-29 09:20:06 +02:00
Andrey Antukh
40910703ee Merge pull request #4930 from penpot/ladybenko-8413-asset-ids
Assert icon and svg IDs in DS components
2024-07-29 08:45:53 +02:00
Belén Albeza
cfc01e03f6 Assert existing icon ID for button* and icon-button* 2024-07-26 14:33:11 +02:00
Belén Albeza
10ef9d696c Assert valid svg id in raw-svg* 2024-07-26 14:24:47 +02:00
Belén Albeza
138ece085e Assert existing icon ID for icon* 2024-07-26 14:24:47 +02:00
alonso.torres
19b2f330dd Merge remote-tracking branch 'origin/plugins-beta-test' into develop 2024-07-26 13:47:12 +02:00
Andrey Antukh
e48aa909da Merge pull request #4919 from penpot/ladybenko-7869-ds-buttons
Implement design system buttons
2024-07-26 13:18:21 +02:00
Andrey Antukh
b122db447a Merge pull request #4928 from penpot/alotor-plugins-10
Alotor plugins 10
2024-07-26 13:17:16 +02:00
alonso.torres
642c4fc9d1 ⬆️ Update plugins runtime 2024-07-26 12:42:31 +02:00
alonso.torres
4d57f33371 Change local storage access 2024-07-26 12:42:31 +02:00
alonso.torres
60c63e4558 Add undo block api to plugins 2024-07-26 12:42:31 +02:00
alonso.torres
aa90232bf9 Add export method into API 2024-07-26 12:42:31 +02:00
Belén Albeza
cf7439b1b4 📚 Add buttons documentation for the design system 2024-07-26 11:49:51 +02:00
Belén Albeza
60cba6c9f3 Implement button* and icon-button* for the design system 2024-07-26 11:49:51 +02:00
Andrey Antukh
3eaa997145 Merge remote-tracking branch 'origin/staging' into develop 2024-07-26 08:36:30 +02:00
Alejandro
4b6d3546e0 Merge pull request #4926 from penpot/niwinz-fix-error-report
🐛 Fix regression on error reporting
2024-07-26 08:27:37 +02:00
Alejandro
0bd3d80816 Merge pull request #4925 from penpot/niwinz-resolve-thumbnail-on-frontend
 Resolve file thumbnail on frontend instead of backend
2024-07-26 08:24:29 +02:00
AlexTECPlayz
28cca332e7 🌐 Add translations for: Romanian.
Currently translated at 90.4% (1274 of 1408 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/ro/
2024-07-25 19:09:17 +02:00
Andrey Antukh
a261a57868 Prevent double error asignation on persistence error 2024-07-25 17:17:49 +02:00
Andrey Antukh
af389fe63a 🐛 Fix error reporting regression 2024-07-25 17:17:49 +02:00
Andrey Antukh
defcef3e59 Resolve file thumbnail on frontend instead of backend 2024-07-25 15:17:41 +02:00
Andrey Antukh
025034cb71 Merge remote-tracking branch 'origin/staging' into develop 2024-07-25 11:23:42 +02:00
Andrey Antukh
7fd75336a5 Merge pull request #4918 from penpot/alotor-plugins-9
Alotor plugins 9
2024-07-25 11:04:22 +02:00
Andrey Antukh
5ed49995f0 📎 Update changelog 2024-07-25 10:48:46 +02:00
Andrey Antukh
482901f315 Merge pull request #4922 from penpot/niwinz-staging-inet
 Ip Addr parsing and audit log context forwarding fixes
2024-07-24 23:16:27 +02:00
Andrey Antukh
cb26f341d5 Merge pull request #4921 from penpot/eva-fix-search-label
🐛  Fix search label in translations
2024-07-24 21:27:58 +02:00
Andrey Antukh
69b432eb0e 📎 Fix audit event type naming on oidc 2024-07-24 21:25:55 +02:00
Andrey Antukh
7df9ac5e4f 🐛 Fix audit context forwarding on explicit events 2024-07-24 21:25:55 +02:00
Andrey Antukh
343f3feed3 Improve ip-addr parsing 2024-07-24 21:07:11 +02:00
Andrey Antukh
08c8c47006 Merge pull request #4917 from penpot/superalex-fix-flag-email-verification
🐛 Fix flag email verification
2024-07-24 21:00:29 +02:00
Alejandro Alonso
a6d738f0db 🐛 Fix flag email verification 2024-07-24 20:46:49 +02:00
Eva Marco
1f80827d94 🐛 Fix search label in translations 2024-07-24 17:16:13 +02:00
Eva Marco
af5a189d04 ♻️ Replacing the old Pencil loader with the new Loader component 2024-07-24 17:06:13 +02:00
AlexTECPlayz
7ec80a375a 🌐 Add translations for: Romanian.
Currently translated at 90.1% (1269 of 1408 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/ro/
2024-07-24 16:09:21 +02:00
alonso.torres
285119b2e5 ⬆️ Update plugins runtime 2024-07-24 13:43:50 +02:00
Alejandro
51611fbc09 Merge pull request #4871 from penpot/palba-fix-collapse-groups
🐛 Fix can't collapse colors and typograhies groups when searching assets
2024-07-24 10:20:42 +02:00
Alejandro
c80b35e3ad Merge pull request #4916 from penpot/palba-consolidate-templates-order
 Consolidate templates new order and naming
2024-07-24 09:32:44 +02:00
Pablo Alba
166b8c806c 🐛 Fix can't collapse colors and typograhies groups when searching assets 2024-07-24 09:25:26 +02:00
Pablo Alba
0539337121 🐛 Fix user cannot close comment creation tool 2024-07-24 09:22:53 +02:00
Pablo Alba
50fe715fba 🐛 Fix Components are not dragged from the group to the assets tab 2024-07-24 09:20:54 +02:00
Pablo Alba
81bd30a11b Consolidate templates new order and naming 2024-07-24 09:18:16 +02:00
Eva Marco
e5daa00d73 Add elevation tokens to ds 2024-07-24 09:00:03 +02:00
Belén Albeza
fd58813ec9 Merge pull request #4908 from penpot/eva-add-zindex-to-ds
 Add z-index tokens to the ds
2024-07-24 08:56:35 +02:00
Andrey Antukh
111add1ed6 🐛 Fix issue on merging stanging to develop 2024-07-24 08:40:31 +02:00
Andrey Antukh
a457f8baf5 Merge pull request #4913 from penpot/superalex-fix-files-with-invalid-library-colors
🐛 Fix file with invalid library colors
2024-07-24 08:37:51 +02:00
Eva Marco
12d65c7743 Add z-index tokens to the ds 2024-07-24 08:30:46 +02:00
Andrey Antukh
a100d1d11a Merge remote-tracking branch 'origin/staging' into develop 2024-07-24 08:20:36 +02:00
Andrey Antukh
28c4053ad3 Merge pull request #4914 from penpot/bameda-patch-1
📎 Add Contributing to the TOC
2024-07-23 21:16:59 +02:00
David Barragán Merino
e84d9358d1 📎 Add Contributing to the TOC 2024-07-23 21:15:39 +02:00
Alejandro
3832377e04 Merge pull request #4902 from penpot/niwinz-notifications-improvements
 Improvements to notifications
2024-07-23 16:57:51 +02:00
Andrey Antukh
975efd80cb Add maintenance predefined notification 2024-07-23 16:56:36 +02:00
alonso.torres
2d25df33ce Add write methods to prototype API 2024-07-23 16:55:32 +02:00
Alejandro Alonso
ecb0dc073d 🐛 Fix file with invalid library colors 2024-07-23 16:47:23 +02:00
Andrey Antukh
c51778f391 Merge pull request #4910 from penpot/ladybenko-8394-fix-sourcesans
🐛 Fix font declarations for Source Sans
2024-07-23 16:04:36 +02:00
Alejandro
3553b02c55 Merge pull request #4911 from penpot/main-tmp
 Add timestamp to release build hash
2024-07-23 14:49:10 +02:00
Belén Albeza
20333d8179 🐛 Fix font declarations for Source Sans 2024-07-23 14:24:04 +02:00
Andrey Antukh
434209af7d Add timestamp to release build hash 2024-07-23 14:07:46 +02:00
Alejandro
16ae057b4f Merge pull request #4880 from penpot/niwinz-oidc-fixes
 Several improvements to OIDC and other related code
2024-07-23 11:25:46 +02:00
Alejandro
2431cb40bf Merge pull request #4905 from penpot/niwinz-srepl-improvements
 Add proper deletion/restore helpers to srepl/main
2024-07-23 07:35:55 +02:00
Andrey Antukh
34293326b8 Add proper deletion/restore helpers to srepl/main 2024-07-22 15:17:11 +02:00
Andrey Antukh
57c60716f0 Add minor improvements to notifications-hub component 2024-07-22 13:14:58 +02:00
Andrey Antukh
7e50ab52b9 📎 Add minor improvement on notification message validation 2024-07-22 13:14:58 +02:00
Andrey Antukh
9e0fb44b3f 🐛 Remove unnecesary delay on hide notification banner 2024-07-22 13:14:58 +02:00
Andrey Antukh
142ae32256 Add better call signature for srepl/notify! fn helper 2024-07-22 13:14:58 +02:00
alonso.torres
6454e878dd Page functions for plugins api 2024-07-22 13:10:10 +02:00
alonso.torres
d13b9ef3ea 🐛 Fix wrap not working in plugins 2024-07-22 11:27:29 +02:00
alonso.torres
26fa2a71ea 🐛 Fix problem with reset alignment on change text 2024-07-22 11:27:12 +02:00
Andrey Antukh
46ed61f070 Merge pull request #4878 from penpot/alotor-plugins-8
Alotor plugins 8
2024-07-22 11:17:03 +02:00
Eva Marco
09cd45fd8b Merge pull request #4876 from penpot/ladybenko-7914-spacing-tokens
 Add spacing tokens to the design system
2024-07-22 08:11:54 +02:00
Eva Marco
d162e3e11b Merge pull request #4879 from penpot/ladybenko-8349-storybook-theme
 Enable themes in Storybook
2024-07-22 07:47:46 +02:00
Andrey Antukh
085b933796 Update default buffers and resolver on devenv nginx config 2024-07-12 14:26:21 +02:00
Belén Albeza
a5dd2683cd 💄 Remove deprecated StoryWrapper helper component 2024-07-12 14:05:44 +02:00
Belén Albeza
ebda46f748 Support theme switching within Storybook 2024-07-12 14:05:44 +02:00
Belén Albeza
0d8c98dcfe ⬆️ Upgrade storybook (patch version) 2024-07-12 14:05:44 +02:00
Belén Albeza
174ca6bed5 Merge pull request #4870 from penpot/eva-add-loader-component-to-ds
  Add loader component to ds
2024-07-12 14:04:10 +02:00
Andrey Antukh
8dfc97d875 Add jwks loading on gitlab oidc provider 2024-07-12 14:03:48 +02:00
Eva Marco
271be57c99 Add loader component to the ds 2024-07-12 13:51:33 +02:00
Andrey Antukh
3b48be808c 💄 Add minor naming change on calling logging on oidc ns 2024-07-12 13:39:32 +02:00
Andrey Antukh
a54160965d 🐛 Fix ip-addr parsing issue when it comes with port 2024-07-12 13:38:46 +02:00
Andrey Antukh
f4b59cc5a0 Normalize external-session-id parsing from request 2024-07-12 13:38:46 +02:00
Andrey Antukh
d52f2b18a5 Add context to OIDC errors 2024-07-12 13:38:46 +02:00
alonso.torres
423d2fbb92 ⬆️ Update plugins runtime 2024-07-12 13:36:00 +02:00
alonso.torres
21b15167dd Add detach method to plugins 2024-07-12 13:36:00 +02:00
alonso.torres
59005e3bb8 Changes to plugin events 2024-07-12 13:36:00 +02:00
alonso.torres
60f637e947 Add parent property to shapes 2024-07-12 13:36:00 +02:00
alonso.torres
8ded4811bb Internal refactor of plugin installs 2024-07-12 13:36:00 +02:00
Eva Marco
3900b37f5c Merge pull request #4874 from penpot/ladybenko-8008-upgrade-storybook8
Upgrade to Storybook 8
2024-07-12 10:07:14 +02:00
TheScientistPT
cfb5a98cac 🌐 Add translations for: Portuguese (Portugal).
Currently translated at 99.5% (1402 of 1408 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/pt_PT/
2024-07-11 22:09:23 +02:00
Nima K
03ddb32556 🌐 Add translations for: Persian.
Currently translated at 48.7% (686 of 1408 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/fa/
2024-07-11 22:09:22 +02:00
Belén Albeza
1398bcbc8c Add spacing tokens to the design system 2024-07-11 18:08:33 +02:00
Belén Albeza
93d9438f6c 📚 Adapts Heading docs/stories to be as the Text component 2024-07-11 17:06:15 +02:00
Belén Albeza
0fce6c5ebb 🐛 Fix broken typography docs after upgrading to v8 2024-07-11 17:01:04 +02:00
Belén Albeza
a03eeb63e7 ⬆️ Upgrade to storybook v8 2024-07-11 15:41:24 +02:00
Alejandro Alonso
4dd7880744 Add create-devenv command to manage.sh 2024-07-11 13:24:20 +02:00
Eva Marco
5ab7123566 Merge pull request #4865 from penpot/ladybenko-8347-storybook-controls
Use Storybook controls for stories
2024-07-11 13:06:56 +02:00
Belén Albeza
ba4732c526 🐛 Fix text component misbehaving when prop is empty string 2024-07-11 12:56:25 +02:00
Alejandro
73fb95976c Merge pull request #4863 from penpot/niwinz-refactor-backend-config
♻️ Refactor configuration validation
2024-07-11 12:27:59 +02:00
Belén Albeza
b473b7905d 🐛 Fix Text docs re: accessibility 2024-07-11 12:24:19 +02:00
Belén Albeza
ba36023ae6 Revamp RawSvg stories and update prop name 2024-07-11 10:06:46 +02:00
Alejandro Alonso
48e7cd28b3 Merge remote-tracking branch 'origin/staging' into develop 2024-07-11 09:24:17 +02:00
Alejandro
54711b0d25 Merge pull request #4864 from penpot/niwinz-kondo-fix
🐛 Fix exception on clj-kondo extension hook fn
2024-07-11 09:22:25 +02:00
Eva Marco
e916c97491 Merge pull request #4867 from penpot/ladybenko-8348-fix-pencil-loader
🐛 Fix pencil loader in dashboard
2024-07-11 08:56:04 +02:00
Belén Albeza
cdabf0d6b9 🐛 Fix pencil loader in dashboard 2024-07-11 08:46:16 +02:00
Belén Albeza
7e61acc4da 💄 Update icon prop name 2024-07-10 16:15:07 +02:00
Belén Albeza
d7ca4d49dc Revamp icon stories 2024-07-10 15:53:27 +02:00
Belén Albeza
df858c2c7d 📎 Move icon and raw-svg components to a common subdir 2024-07-10 15:42:19 +02:00
Belén Albeza
9d3a282c0a 📎 Move typography-related components to their own folder 2024-07-10 15:33:38 +02:00
Andrey Antukh
9174bb140b ♻️ Refactor configuration validation
Replace spec with schema
2024-07-10 15:16:28 +02:00
Belén Albeza
54da6832f3 Revamp Text stories to display controls + rename tag prop to as 2024-07-10 13:34:09 +02:00
Belén Albeza
508f4fcd3c Revamp Heading stories to display controls 2024-07-10 13:31:56 +02:00
Andrey Antukh
eaaff76aad 🐛 Fix exception on clj-kondo extension hook fn
The exception is hidden on normal cli invocatin of clj-kondo
and hapens when component with empty params is defined.
2024-07-10 13:27:12 +02:00
Belén Albeza
0d0b5ead86 📎 Remove unused storybook addons + other libs 2024-07-10 12:44:15 +02:00
Belén Albeza
7f6bfacff1 Merge pull request #4857 from penpot/eva-add-text-component-to-storybook
 Add text component to storybook
2024-07-10 12:31:42 +02:00
Eva Marco
7bd5d31094 Add text component to storybook 2024-07-10 12:18:37 +02:00
Eva Marco
645bc32121 Add new heading component to the DS 2024-07-10 12:03:55 +02:00
Belén Albeza
6e55260160 Merge pull request #4851 from penpot/eva-add-heading-component-to-storybook
 Add heading component to storybook
2024-07-10 12:01:57 +02:00
Eva Marco
2abbb0d359 Add new heading component to the DS 2024-07-10 11:46:06 +02:00
Nima K
b13238eb30 🌐 Add translations for: Persian.
Currently translated at 47.9% (675 of 1408 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/fa/
2024-07-09 18:09:34 +02:00
Alejandro Alonso
f09cfedebc Merge remote-tracking branch 'origin/staging' into develop 2024-07-09 14:12:57 +02:00
Alejandro
ff43d43020 Merge pull request #4861 from penpot/niwinz-auth-oidc-reject-bugfix
🐛 Fix unexpected error when user explictly reject oidc auth
2024-07-09 14:11:59 +02:00
Andrey Antukh
0ae8cb4979 🐛 Do not report explicit user reject as error on oidc auth process 2024-07-09 13:57:48 +02:00
Andrey Antukh
fc1495fdd1 🐛 Fix unexpected error when user explictly reject oidc auth 2024-07-09 13:51:07 +02:00
Alejandro
74622919f6 Merge pull request #4860 from penpot/palba-testab-template-order
🎉 Test A/B for templates order and names
2024-07-09 12:48:37 +02:00
Pablo Alba
4b4b160ea8 🎉 Test A/B for templates order and names 2024-07-09 12:35:48 +02:00
Andrey Antukh
0a86d9d515 Merge remote-tracking branch 'origin/staging' into develop 2024-07-09 12:16:45 +02:00
Alejandro
2baab838e4 Merge pull request #4859 from penpot/hiru-fix-export-include-libs
Fix embed assets in unpublish and export
2024-07-09 12:13:29 +02:00
Andrés Moya
29d0499725 🐛 Fix embed assets in unpublish and export 2024-07-09 11:51:52 +02:00
Andrey Antukh
d99f4f62ea Merge pull request #4858 from penpot/superalex-update-release-name
 Update release 2.1.0 name
2024-07-09 10:22:33 +02:00
Alejandro Alonso
90f545ae6d Update release 2.1.0 name 2024-07-09 10:18:54 +02:00
Andrey Antukh
b295b79565 Merge pull request #4838 from penpot/superalex-fix-size-presets-dont-work-well
🐛 Size presets landscape doesn't work well
2024-07-09 08:26:07 +02:00
Eva Marco
808ed6a98b Merge pull request #4853 from penpot/ladybenko-8291-update-assets
Update icons and svg assets (design system)
2024-07-09 08:12:36 +02:00
Eva Marco
2bb59671dd Merge pull request #4856 from penpot/ladybenko-8337-enable-ds-css-override
Enable design system CSS override + fix debug css compiling
2024-07-09 08:11:07 +02:00
Belén Albeza
fb6ebcd074 🐛 Fix debug css being included in prod builds 2024-07-08 15:57:35 +02:00
Belén Albeza
44a2a63fb8 Ensure DS scss modules are compiled before the app css modules 2024-07-08 15:57:35 +02:00
Belén Albeza
eae19e8252 📎 Remove leftover code 2024-07-08 15:57:35 +02:00
Andrey Antukh
1b05e7aa36 Merge pull request #4852 from penpot/alotor-plugins-7
 Small improvements over plugin manager
2024-07-08 09:04:44 +02:00
Belén Albeza
be9a2767ea 📎 Remove unused rocket icon 2024-07-05 15:28:25 +02:00
Belén Albeza
6a18791c30 Add character icons 2024-07-05 15:26:45 +02:00
alonso.torres
2cc3f65323 Small improvements over plugin manager 2024-07-05 15:16:09 +02:00
Belén Albeza
63d1b558d1 Add percentage icon and update puzzle icon 2024-07-05 15:09:01 +02:00
Belén Albeza
cfbfda925b 📚 Fix typo in RawSvg storybook docs 2024-07-05 14:57:22 +02:00
Belén Albeza
fd1ab29920 Update v2-related svg assets 2024-07-05 14:34:59 +02:00
alonso.torres
35f4a07d27 Merge remote-tracking branch 'origin/plugins-beta-test' into develop 2024-07-05 11:12:58 +02:00
Eva Marco
9ce3f6da45 Merge pull request #4845 from penpot/ladybenko-8265-raw-svg-component
RawSVG component (design system) + generate SVG sprite for assets
2024-07-05 09:44:35 +02:00
Belén Albeza
b8b199c5ec Merge pull request #4844 from penpot/eva-fix-visual-test
🐛  Fix workspace visual test for assets modal
2024-07-05 09:23:22 +02:00
Belén Albeza
e492284abe Merge pull request #4843 from penpot/eva-remove-unused-locale-fn
♻️  Remove unused locale fn
2024-07-05 09:22:24 +02:00
Eva Marco
3d5e064358 ♻️ Remove unused locale function 2024-07-05 09:04:34 +02:00
Andrey Antukh
6f8ce1fc5a Merge pull request #4849 from penpot/alotor-plugins-6
 Add events for plugins
2024-07-04 17:17:38 +02:00
Andrey Antukh
5ae30ea9bc Merge pull request #4850 from penpot/alotor-bug-api-svg
🐛 Fix problem when creating SVG images
2024-07-04 17:15:35 +02:00
Belén Albeza
8959d39356 Merge pull request #4837 from penpot/eva-ds-foundations-typography
 Add typography ds tokens
2024-07-04 16:11:25 +02:00
alonso.torres
aded9f1a36 🐛 Fix problem when creating SVG images 2024-07-04 16:01:02 +02:00
Belén Albeza
3a34eb1357 🐛 Fix flakiness of visual workspace test (assets tab) 2024-07-04 15:45:50 +02:00
alonso.torres
c2564eaf65 Change spec location 2024-07-04 15:16:58 +02:00
alonso.torres
53d3b2abbc Add events for plugins 2024-07-04 15:16:34 +02:00
Belén Albeza
5d90c463a3 📚 Add docs for RawSvg component 2024-07-04 14:48:57 +02:00
Belén Albeza
5309da2eee 📎 Add storybook helper components and improve current stories 2024-07-04 14:11:03 +02:00
Andrey Antukh
d1dd13fde9 Merge pull request #4842 from penpot/alotor-plugins-5
Alotor plugins 5
2024-07-04 13:59:48 +02:00
alonso.torres
0a83306015 ⬆️ Update plugins runtime 2024-07-04 13:57:04 +02:00
Belén Albeza
203a39f07c ♻️ Rename IconGrid to StoryGrid (storybook helper component) 2024-07-04 13:05:23 +02:00
Alejandro
85579b253f Merge pull request #4681 from penpot/niwinz-enhancements-2
🔥 Replace spec usage on RPC methods with schema
2024-07-04 12:56:41 +02:00
Eva Marco
1ca751bc42 🐛 Fix workspace visual test for assets modal 2024-07-04 12:41:48 +02:00
Andrey Antukh
f344eee778 🐛 Fix backend test initialization code 2024-07-04 12:30:28 +02:00
Andrey Antukh
28c2197ba7 ♻️ Add string length validation to backend RPC methods fields 2024-07-04 12:30:28 +02:00
Andrey Antukh
0721760900 Add better schema for shape export property 2024-07-04 12:30:28 +02:00
Andrey Antukh
45c77f97ce 📎 Fix code style issue not catched by the linter
Comment indentantion
2024-07-04 12:30:28 +02:00
Andrey Antukh
05fb46a573 Accept uri instances on http client 2024-07-04 12:30:28 +02:00
Andrey Antukh
ad6a864478 🔥 Replace spec with schema on search RPC methods 2024-07-04 12:30:28 +02:00
Andrey Antukh
37fcc74ef8 🔥 Replace spec with schema on media RPC methods 2024-07-04 12:30:28 +02:00
Andrey Antukh
c4cf745d77 🔥 Replace spec with schema on ldap RPC methods 2024-07-04 12:30:28 +02:00
Andrey Antukh
85108672bf 🔥 Replace spec with schema on file-thumbnails RPC methods 2024-07-04 12:30:28 +02:00
Andrey Antukh
969c9105fd 🔥 Replace spec with schema on feedback RPC methods 2024-07-04 12:30:28 +02:00
Andrey Antukh
073621f29a 🔥 Replace spec with schema on demo RPC methods 2024-07-04 12:30:28 +02:00
Andrey Antukh
bbc0089166 🔥 Replace spec with schema on verify-token RPC methods 2024-07-04 12:30:28 +02:00
Andrey Antukh
268f1d40aa 🔥 Replace spec with schema on file-share RPC methods 2024-07-04 12:30:28 +02:00
Andrey Antukh
e9a28b034f 🔥 Replace spec with schema on file RPC methods 2024-07-04 12:30:28 +02:00
Andrey Antukh
bfca324623 🔥 Replace spec with schema on project rpc methods 2024-07-04 12:30:28 +02:00
Andrey Antukh
279c6337e4 🔥 Replace spec with schema on access-token rpc methods 2024-07-04 12:30:28 +02:00
Andrey Antukh
368917f7f5 🔥 Replace spec with schema on webhooks rpc methods 2024-07-04 12:30:28 +02:00
Andrey Antukh
f973faa409 📎 Add missing SPEC tag on doc entry template 2024-07-04 12:30:28 +02:00
Andrey Antukh
a0339132dd 📎 Update cljfmt config 2024-07-04 12:30:28 +02:00
Andrey Antukh
40f947fc9f 🐛 Fix issue with schema uri decoder 2024-07-04 12:30:28 +02:00
Andrey Antukh
d2bedec59c Unify naming of schema registering functions 2024-07-04 12:30:28 +02:00
alonso.torres
1b93ccdec9 Remove duplicate permissions in confirm dialog 2024-07-04 12:07:54 +02:00
Alejandro Alonso
2921b62b37 Merge remote-tracking branch 'origin/staging' into develop 2024-07-04 11:56:21 +02:00
Belén Albeza
ffee6c63eb Merge pull request #4841 from penpot/superalex-release-notes-2-1
 Release notes for 2.1
2024-07-04 11:55:25 +02:00
alonso.torres
83f3ae1fbd Change plugins url 2024-07-04 11:52:31 +02:00
Eva Marco
66d97cb2e0 Add typography ds tokens 2024-07-04 11:18:05 +02:00
Alejandro Alonso
0ec1bb7a22 Release notes for 2.1 2024-07-04 11:16:20 +02:00
Belén Albeza
4ecaaba1e5 Add RawSvg component to the design system 2024-07-04 10:11:12 +02:00
Belén Albeza
c52da573c5 📎 Fix react warning on icon* component 2024-07-04 09:47:37 +02:00
Belén Albeza
4ac18e2ef0 🐛 Fix cursors svg duplicating icons sprites 2024-07-04 09:20:18 +02:00
Belén Albeza
f05e1354ff 🔧 Add assets svg sprite generation 2024-07-04 09:20:18 +02:00
Andrey Antukh
bafe2ab985 Merge pull request #4832 from penpot/ladybenko-7866-icon-component
Implement icon component (design system)
2024-07-03 19:33:16 +02:00
Andrey Antukh
0d13a12d64 Merge pull request #4840 from penpot/alotor-plugins-4
Alotor plugins 4
2024-07-03 16:49:47 +02:00
alonso.torres
deb0fab156 🐛 Fix small visual problems 2024-07-03 15:35:43 +02:00
Belén Albeza
c181887266 📎 Remove unused example simple_button component 2024-07-03 15:26:11 +02:00
Belén Albeza
a624a10c85 🐛 Fix scrolling not working on storybook mdx files 2024-07-03 15:26:11 +02:00
Belén Albeza
6295fbf7e2 Implement icon* component 2024-07-03 15:26:11 +02:00
Belén Albeza
c6a7ad0520 🐛 Fix template generation for storybook 2024-07-03 15:25:30 +02:00
Belén Albeza
de89dfe27f 📎 Remove unused legacy icons preview 2024-07-03 15:25:30 +02:00
alonso.torres
a8463f349a New plugin attributes 2024-07-03 15:23:05 +02:00
Belén Albeza
3b6ed823b9 Merge pull request #4839 from penpot/niwinz-rumext-linter
 Add better linter for rumext defc macro
2024-07-03 15:22:55 +02:00
alonso.torres
80e17f8cfc Add new signature for the run-store test helper 2024-07-03 15:22:42 +02:00
Andrey Antukh
8fae4550c3 Add better linter for rumext defc macro 2024-07-03 14:36:29 +02:00
Alejandro Alonso
2944860696 🐛 Size presets landscape doesn't work well 2024-07-03 13:35:14 +02:00
Alejandro Alonso
9125b46ca5 Merge remote-tracking branch 'origin/staging' into develop 2024-07-03 08:46:26 +02:00
Alejandro
7ed25d2dba Merge pull request #4765 from penpot/niwinz-refactor-forms
♻️ Refactor forms (spec -> schema)
2024-07-03 08:45:42 +02:00
Andrey Antukh
0fa8aca6e2 Add minor improvements to common.schema ns 2024-07-03 08:25:51 +02:00
Andrey Antukh
7be79c10fd ♻️ Refactor forms
Mainly replace spec with schema with better
and more reusable validations
2024-07-03 08:25:51 +02:00
Andrey Antukh
f095e1b29f Replace custom all-spaces? fn with generic str/blank? 2024-07-02 17:47:58 +02:00
Andrey Antukh
96822082bd Revert " Rehash and sync translations"
This reverts commit 5b6fc19e00.
2024-07-02 17:47:29 +02:00
Aitor Moreno
c637912337 Merge pull request #4822 from penpot/niwinz-translation-management-script
🎉 Add new translations management script
2024-07-02 16:20:25 +02:00
AzazelN28
5b6fc19e00 Rehash and sync translations 2024-07-02 16:04:57 +02:00
Andrey Antukh
f6435461a1 Merge pull request #4835 from penpot/alotor-plugins-3
🐛 Fix some problems in plugins
2024-07-02 15:44:50 +02:00
AzazelN28
83e51abd35 🐛 Fix package.json translation scripts 2024-07-02 15:41:00 +02:00
Andrey Antukh
8d6791105a Merge pull request #4833 from penpot/superalex-add-extra-info-to-create-team-response
 Add extra info to create team response
2024-07-02 15:37:42 +02:00
Andrey Antukh
dab88404c0 Merge pull request #4834 from penpot/ladybenko-fix-layer-width
🐛 Fix layer width on the left sidebar
2024-07-02 15:37:22 +02:00
alonso.torres
c66ff74f21 🐛 Fix some problems in plugins 2024-07-02 15:30:35 +02:00
Belén Albeza
769655f565 🐛 Fix layer width on the left sidebar 2024-07-02 15:18:27 +02:00
Andrey Antukh
139dd7d80f 🎉 Add new translations management script 2024-07-02 15:11:56 +02:00
Andrey Antukh
62cea62356 Merge pull request #4816 from penpot/alotor-plugins-2
Improvements over plugins subsystem
2024-07-02 13:43:15 +02:00
Alejandro Alonso
f051137098 Add extra info to create team response 2024-07-02 13:36:12 +02:00
alonso.torres
58fa10a0d5 ⬆️ Update plugins runtime 2024-07-02 11:08:56 +02:00
alonso.torres
395a91c00c Plugins permissions review 2024-07-02 11:01:43 +02:00
alonso.torres
741bf3b666 New plugins permissions dialog 2024-07-02 11:01:43 +02:00
alonso.torres
fbce59e81f Improved text handling in plugins 2024-07-02 10:41:06 +02:00
alonso.torres
ac58a5b8fa Improved transformation from and to JS for plugins 2024-07-02 10:41:06 +02:00
alonso.torres
42230f2630 Change shapes color 2024-07-02 10:41:06 +02:00
Andrey Antukh
675a31796c Merge pull request #4823 from penpot/superalex-improve-audit-log-external-origin-events
 improve audit log external origin events
2024-07-02 08:29:33 +02:00
Alejandro Alonso
8dcd538bd2 Improve external origin events for audit_log 2024-07-02 08:14:22 +02:00
Belén Albeza
9a188fd792 Merge pull request #4830 from penpot/eva-ds-color-foundations
 Add DS foundation colors
2024-07-01 16:04:24 +02:00
Eva Marco
6c68a34d63 Add DS foundation colors 2024-07-01 15:10:46 +02:00
Eva Marco
746b448f30 Merge pull request #4825 from penpot/ladybenko-8224-setup-ds
Setup design system
2024-07-01 12:49:22 +02:00
Belén Albeza
b5aba58aac Make storybook wrapper to render both dark and light themes 2024-07-01 11:14:42 +02:00
Belén Albeza
2bb7726180 📎 Remove unneeded icons export in the storybook target 2024-07-01 11:14:42 +02:00
Belén Albeza
24b607cad3 💄 Move the stub design system component to its own ds folder 2024-07-01 11:14:42 +02:00
Eva Marco
087d0e90e6 Merge pull request #4821 from penpot/ladybenko-8182-prettier
Add prettier for JS files
2024-07-01 10:48:01 +02:00
Belén Albeza
e448951d6f Add CI rule for checking JS format 2024-07-01 10:29:57 +02:00
Belén Albeza
ecbedf847f 💄 Reformat affected JS files 2024-07-01 10:29:57 +02:00
Belén Albeza
3efd5cb9e8 Add prettier JS commands to package.json 2024-07-01 10:29:57 +02:00
Belén Albeza
e1dc964c4c Upgrade prettier and use specific settings for scss files only 2024-07-01 10:23:19 +02:00
The_BadUser
295c932646 🌐 Add translations for: Russian.
Currently translated at 99.6% (1403 of 1408 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/ru/
2024-06-30 21:10:08 +02:00
The_BadUser
5b9f4128f3 🌐 Add translations for: Russian.
Currently translated at 89.3% (1258 of 1408 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/ru/
2024-06-29 01:26:20 +02:00
The_BadUser
100f1229ce 🌐 Add translations for: Russian.
Currently translated at 75.9% (1070 of 1408 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/ru/
2024-06-29 00:09:23 +02:00
Aryiu
adf24cd274 🌐 Add translations for: Catalan.
Currently translated at 77.1% (1086 of 1408 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/ca/
2024-06-29 00:09:22 +02:00
Andrey Antukh
de1d154e9c Merge pull request #4824 from penpot/alotor-fix-plugins
🐛 Fix problem with recursive properties
2024-06-28 16:21:58 +02:00
alonso.torres
4345584384 🐛 Fix problem with recursive properties 2024-06-28 14:57:14 +02:00
Alejandro Alonso
ba1adf91ca Merge remote-tracking branch 'origin/staging' into develop 2024-06-28 11:09:37 +02:00
Andrey Antukh
384ad2e6fa Merge pull request #4813 from penpot/superalex-tracking-teams-and-invitations-in-posthog
 Add extra events info to track teams and invitations
2024-06-28 11:08:30 +02:00
Andrey Antukh
024b08de06 Merge remote-tracking branch 'origin/staging' into develop 2024-06-28 10:37:22 +02:00
Andrey Antukh
c090a11e5b Normalize audit event origin tracking on frontend and backend 2024-06-28 10:30:26 +02:00
Alejandro Alonso
f6b367cdca Add extra events info to track teams and invitations 2024-06-28 10:30:26 +02:00
Alejandro
4e5eabbf05 Merge pull request #4781 from penpot/ladybenko-8110-clean-global-css
 Clean global css styles
2024-06-28 08:48:21 +02:00
Andrey Antukh
5b9d2663c0 Merge remote-tracking branch 'origin/main' into staging 2024-06-28 08:18:30 +02:00
Alejandro
5e5c105d92 Merge pull request #4817 from penpot/niwinz-hotfix-1
🐛 More fixes on account deletion process
2024-06-28 07:43:07 +02:00
Alejandro
9c2c2fec6a Merge pull request #4815 from penpot/niwinz-bugfix-2
🐛 Backport from main account deletion bugfixes
2024-06-28 07:35:53 +02:00
Andrey Antukh
56160cf64d 🐛 Fix error handling on verify-token page 2024-06-27 16:11:43 +02:00
Andrey Antukh
c45a105186 🐛 Set correct order of execution for logged-out event 2024-06-27 16:11:37 +02:00
Andrey Antukh
f364666d48 🐛 Fix error handling on verify-token page 2024-06-27 16:10:26 +02:00
Andrey Antukh
7facd69039 🐛 Set correct order of execution for logged-out event 2024-06-27 16:10:04 +02:00
Belén Albeza
c9258b5526 Remove workspace partial scss stylesheet 2024-06-27 15:35:57 +02:00
Belén Albeza
ce9fb80558 📎 Remove unused css for loader 2024-06-27 15:35:57 +02:00
Belén Albeza
cd8e2540de Use CSS modules for styling the debug icons preview page 2024-06-27 15:35:57 +02:00
Belén Albeza
9a2ee806e4 Clean up base scss 2024-06-27 15:35:57 +02:00
Belén Albeza
b192887d19 Remove framework scss stylesheet 2024-06-27 15:35:57 +02:00
Belén Albeza
b6e918b024 Remove unused legacy sass files 2024-06-27 15:35:57 +02:00
Belén Albeza
ed174d16d1 Remove unused animation mixin 2024-06-27 15:35:57 +02:00
Belén Albeza
6b8108afda Make reset css to be included first thing in our styles 2024-06-27 15:35:57 +02:00
Belén Albeza
49fd000217 Clean up fonts scss files 2024-06-27 15:35:57 +02:00
Belén Albeza
0c3f47b0c3 Clean up unused selectors / mixins / sass vars 2024-06-27 15:35:57 +02:00
Belén Albeza
2d53b96a15 Initial clean up of framework scss 2024-06-27 15:35:57 +02:00
Belén Albeza
540875c41e Remove unused css var colors 2024-06-27 15:35:57 +02:00
Belén Albeza
595f153d85 Remove importing animate.css 2024-06-27 15:35:57 +02:00
Belén Albeza
0cbc3487b0 🔧 Tweak the pixel diff ratio of playwright 2024-06-27 15:35:57 +02:00
Alejandro
b0fea30770 Merge pull request #4814 from penpot/niwinz-hotfix-1
🐛 Add missing logged-out event after account deletion
2024-06-27 14:04:16 +02:00
Andrey Antukh
17015c5353 🐛 Add missing logged-out event after account deletion 2024-06-27 14:00:52 +02:00
Andrey Antukh
ba721def26 Add srepl helpers for profile deletion handling 2024-06-27 14:00:52 +02:00
Andrey Antukh
f9af7f0f09 🐛 Make profile deletion follow the delete-object flow
This removes the need of the specific task for cleaning
orphan teams.
2024-06-27 14:00:52 +02:00
Andrey Antukh
56476acc19 🐛 Fix error handling on account deletion process 2024-06-27 13:56:39 +02:00
Andrey Antukh
67489c0bb9 🐛 Fix profile deletion issue with 1 participant 2024-06-27 13:56:39 +02:00
Andrey Antukh
272edec3c6 🐛 Add missing logged-out event after account deletion 2024-06-27 13:53:30 +02:00
Alejandro
78addf00b4 Merge pull request #4812 from penpot/niwinz-hotfix-1
🐛 Fix account deletion process issues
2024-06-27 13:02:55 +02:00
Andrey Antukh
2cddbc8a3d 🐛 Fix error handling on account deletion process 2024-06-27 12:16:51 +02:00
Andrey Antukh
7e44ae62a2 🐛 Fix profile deletion issue with 1 participant 2024-06-27 12:16:51 +02:00
Alejandro Alonso
978ac68474 Merge remote-tracking branch 'origin/staging' into develop 2024-06-27 09:54:48 +02:00
Alejandro Alonso
40b43c6c5b 🐛 Fix lost image colors in library when export/import using zip format 2024-06-27 09:54:02 +02:00
Alejandro Alonso
034170afac 🐛 Export/import of images doesn't work for .zip format 2024-06-27 09:54:02 +02:00
Alejandro Alonso
045e83e871 Merge remote-tracking branch 'origin/staging' into develop 2024-06-27 08:44:23 +02:00
Alejandro
46a9535f35 Merge pull request #4810 from penpot/niwinz-bugfix-11
🐛 Add migration for fix path shapes with invalid curve segment params
2024-06-27 08:02:00 +02:00
Andrey Antukh
0239139b4b Merge pull request #4802 from penpot/jordisala1991-feature/no-direct-download
 Return blob when exporting using the lib-penpot
2024-06-27 07:59:38 +02:00
Alejandro
8c411e7727 Merge pull request #4808 from penpot/ladybenko-fix-playwright-test-mac-shortcut
🐛 Fix playwright test mac shortcut
2024-06-27 07:48:36 +02:00
Alejandro
ff4d66ec75 Merge pull request #4806 from penpot/niwinz-bugfix-10
🐛 Properly report erorrs on importation
2024-06-27 07:37:58 +02:00
Alejandro
e3f4258252 Merge pull request #4796 from penpot/palba-bugfixing-007
🐛 Bugfixing
2024-06-27 07:35:42 +02:00
Pablo Alba
950d6195f6 🐛 Fix import file message does not detect 0 as error 2024-06-27 07:35:30 +02:00
Pablo Alba
a56e7e383f 🐛 Fix 'Detach instance' shortcut is not working 2024-06-27 07:35:29 +02:00
Pablo Alba
f786aff3fc 🐛 Fix can't collapse groups when searching in the assets tab 2024-06-27 07:35:28 +02:00
Andrey Antukh
f393ce9273 🐛 Add migration for fix path shapes with invalid curve segment params 2024-06-26 19:46:29 +02:00
Belén Albeza
16d0b925fa 🐛 Fix workspace 'make group' test on Mac 2024-06-26 17:02:24 +02:00
Belén Albeza
f306ddb51f 🐛 Fix onboarding playwright test on CI mode 2024-06-26 17:01:58 +02:00
Andrey Antukh
16a0e1f578 Merge pull request #4805 from penpot/superalex-fix-selected-colors-do-not-appear-in-color-palette
🐛 Selected colors do not appear in the color palette
2024-06-26 15:04:40 +02:00
Andrey Antukh
1c1929ed32 📎 Add helpers for process deletion cascade of old objects 2024-06-26 15:00:47 +02:00
Andrey Antukh
37d0cec265 🐛 Properly report importation errors 2024-06-26 14:59:38 +02:00
Alejandro Alonso
9ca1535a65 🐛 Selected colors do not appear in the color palette 2024-06-26 12:57:53 +02:00
Andrey Antukh
8a63089773 Merge pull request #4801 from penpot/superalex-fix-color-library-loses-association
🐛 Color library loses association with shapes when exporting/impo…
2024-06-26 11:28:45 +02:00
Andrey Antukh
4faf9bbff1 📎 Add minor change on how promise is created from observable 2024-06-26 11:27:30 +02:00
Jordi Sala Morales
44b6d1a516 Return blob when exporting using the lib-penpot 2024-06-26 11:19:09 +02:00
Alejandro Alonso
58466e6488 🐛 Color library loses association with shapes when exporting/importing the document 2024-06-26 10:40:30 +02:00
Alejandro Alonso
4ed6e1e8ec Merge remote-tracking branch 'origin/staging' into develop 2024-06-26 07:42:50 +02:00
Alejandro
3bb2573dec Merge pull request #4795 from penpot/niwinz-bugfix-8
🐛 Bugfixes
2024-06-26 07:41:22 +02:00
Alejandro
4437fc43e4 Merge pull request #4799 from penpot/ladybenko-fix-visual-regression-tests
Fix broken visual regression test + refactor Dashboard POM
2024-06-26 07:01:49 +02:00
Andrey Antukh
253e5a11fc Merge remote-tracking branch 'origin/staging' into develop 2024-06-25 16:33:52 +02:00
Andrey Antukh
3a30e6b29e Merge pull request #4798 from penpot/superalex-fix-alt-duplicate-shapes
🐛 Fix duplicate shapes with alt key
2024-06-25 16:32:24 +02:00
Alejandro Alonso
6e734f2eac Merge remote-tracking branch 'origin/staging' into develop 2024-06-25 15:54:32 +02:00
Alejandro Alonso
686f59b0de 🐛 Fix duplicate shapes with alt key 2024-06-25 15:53:17 +02:00
Andrey Antukh
fc30e81072 🐛 Make component changes watcher look on local commits only 2024-06-25 15:47:24 +02:00
Belén Albeza
30edca024a Remove unneeded draftsFile and newFile locators in dashboard POM 2024-06-25 15:26:49 +02:00
Andrés Moya
798970a923 🐛 Rework svg import of deleted components 2024-06-25 15:23:52 +02:00
Andrés Moya
6aeb87a122 🐛 Rework svg export of deleted components 2024-06-25 15:23:52 +02:00
Belén Albeza
c14f783d94 Remove redundant locators for Dashboard POM 2024-06-25 15:16:13 +02:00
Belén Albeza
8f3452c0af Avoid using unneeded test ids in dashboard POM 2024-06-25 14:57:37 +02:00
Andrey Antukh
ec4260830c ♻️ Add API consistency fixes for task calling
Also adds a helper for calling tasks synchronously
2024-06-25 13:24:17 +02:00
Andrey Antukh
aa1cf3e03a Add some redundancy to delete_object task 2024-06-25 13:06:44 +02:00
Belén Albeza
97a1b59861 💄 Reformat DashboardPage.js according to prettier rules 2024-06-25 11:56:31 +02:00
Alejandro Alonso
41aad7558b Merge remote-tracking branch 'origin/staging' into develop 2024-06-25 10:49:32 +02:00
Alejandro
3b5b81b08f Merge pull request #4758 from penpot/superalex-refactor-data-test-attribute
 Refactor data-test attribute
2024-06-25 10:49:03 +02:00
Alejandro Alonso
d48616d510 Merge remote-tracking branch 'origin/staging' into develop 2024-06-25 10:18:42 +02:00
Andrey Antukh
8296e72887 Merge pull request #4793 from penpot/alotor-plugins-2
 Add some missing text properties in plugins
2024-06-25 07:47:34 +02:00
Oğuz Ersen
2648e71f5b 🌐 Add translations for: Turkish.
Currently translated at 100.0% (1408 of 1408 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/tr/
2024-06-24 21:09:19 +02:00
alonso.torres
5771f2f8aa Plugins retrieve selection colors 2024-06-24 15:26:47 +02:00
alonso.torres
f86156b619 Plugins support for code generation 2024-06-24 15:26:21 +02:00
alonso.torres
8ff0015458 Add to plugins connect and fetch libraries 2024-06-24 12:34:35 +02:00
alonso.torres
84ecb99400 Add some missing text properties in plugins 2024-06-24 09:57:57 +02:00
Stas Haas
5160ae364d 🌐 Add translations for: German.
Currently translated at 100.0% (1408 of 1408 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/de/
2024-06-22 10:09:13 +02:00
Andrey Antukh
b9e40b4d82 Merge pull request #4788 from penpot/alotor-plugins-2
Fix problem with plugins initialization
2024-06-21 14:58:42 +02:00
Aitor Moreno
f3333336f0 Merge pull request #4787 from penpot/niwinz-bugfix-8
🐛 Fix thumbnails related issues
2024-06-21 13:23:00 +02:00
Andrey Antukh
b25a9f8626 🐛 Return back to use blob uris for transient thumbnails 2024-06-21 13:12:44 +02:00
Andrey Antukh
7b8d127583 🐛 Fix incorrect frame change detection on thumbnails generation 2024-06-21 13:12:44 +02:00
alonso.torres
4b67c0593d Upload media with data in plugins 2024-06-21 12:46:31 +02:00
alonso.torres
fb1429956a Changed order of plugins initialization 2024-06-21 12:44:35 +02:00
Andrey Antukh
c70d20f95d Merge pull request #4783 from penpot/alotor-plugins-texts
Update plugins
2024-06-21 10:03:52 +02:00
Alejandro
0b6c84f551 Merge pull request #4786 from penpot/niwinz-bugfix-8
 Changes on metrics
2024-06-21 09:42:30 +02:00
Andrey Antukh
31818ec365 Replace other summary metrics with histogram 2024-06-21 09:32:46 +02:00
alonso.torres
47d211cd87 ⬆️ Update plugin runtime 2024-06-21 09:29:09 +02:00
alonso.torres
7fd223893b Expose component properties in components 2024-06-21 09:29:09 +02:00
alonso.torres
1794859468 Review input validation for plugins 2024-06-21 09:29:09 +02:00
alonso.torres
c5c8be4b4a Improve input validation in plugins 2024-06-21 09:29:09 +02:00
alonso.torres
e13d543dcd Add geometry utils 2024-06-21 09:29:09 +02:00
alonso.torres
69fad7a920 Add some utilities for fonts in plugins 2024-06-21 09:29:09 +02:00
alonso.torres
2da5dcb619 Add text ranges support in plugins 2024-06-21 09:29:09 +02:00
Andrey Antukh
f249945dff Include climit into the RPC handler metrics 2024-06-21 09:28:28 +02:00
Andrey Antukh
56556a3f3b Make the penpot_rpc_climit_timing metric as histogram 2024-06-21 09:27:11 +02:00
Alejandro Alonso
a59f31ebe5 Refactor data-test attribute 2024-06-21 09:14:09 +02:00
Stas Haas
3260130042 🌐 Add translations for: German.
Currently translated at 99.8% (1406 of 1408 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/de/
2024-06-21 07:09:15 +00:00
Unreal Vision
c77316f91e 🌐 Add translations for: French.
Currently translated at 100.0% (1408 of 1408 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/fr/
2024-06-21 07:09:14 +00:00
Alejandro
4d0bfb1003 Merge pull request #4785 from penpot/niwinz-bugfix-4
🐛 Remove climit setup for delete-file-object-thumbnail RPC method
2024-06-20 18:47:27 +02:00
Andrey Antukh
afb23bcebe Merge pull request #4784 from penpot/azazeln28-refactor-component-thumbnails-as-configurable
♻️ Refactor component thumbnails as configurable
2024-06-20 17:58:45 +02:00
AzazelN28
7b1bda3a49 ♻️ Refactor component thumbnails as configurable 2024-06-20 17:40:41 +02:00
Andrey Antukh
8e9e967f82 🐛 Remove climit setup for delete-file-object-thumbnail RPC method 2024-06-20 16:49:19 +02:00
Andrey Antukh
d1d384acaf Merge pull request #4782 from penpot/eva-fix-translation-error
🐛 Fix minor onboarding errors
2024-06-20 16:10:34 +02:00
Pablo Alba
018464aedf ♻️ Unify move shape on workspace and relocate on layers panel 2024-06-20 16:00:39 +02:00
Eva Marco
1845e759d3 🐛 Fix a small error on translations and on step number for event 2024-06-20 15:06:19 +02:00
Andrey Antukh
955dadc301 Merge pull request #4780 from penpot/superalex-removing-underline-and-strikethrough-affects-the-previous-text-object
🐛 Removing Underline and Strikethrough Affects the Previous Text …
2024-06-20 12:08:30 +02:00
Alejandro
446edee7c6 Merge pull request #4779 from penpot/ladybenko-7937-login-visual-test
Add temporary visual regression tests for the login page
2024-06-20 11:58:45 +02:00
Alejandro Alonso
c35a818d4c 🐛 Removing Underline and Strikethrough Affects the Previous Text Object 2024-06-20 11:49:10 +02:00
Andrey Antukh
e5cc262644 Merge pull request #4778 from penpot/superalex-fix-crash-when-new-colorpicker-while-image-upload
🐛 Penpot crashes when a new colorpicker is created while uploadin…
2024-06-20 10:36:44 +02:00
Belén Albeza
84350ea71c 📎 Remove dashboard visual tests that depend on specific config flags that are not on by default 2024-06-20 09:49:41 +02:00
Belén Albeza
d4eea973b6 📎 Add temporary visual regression test for login form 2024-06-20 09:49:41 +02:00
Belén Albeza
6d82f41e43 ♻️ Refactor login POM logged out user intercept 2024-06-20 09:49:37 +02:00
Alejandro Alonso
4884a11102 🐛 Penpot crashes when a new colorpicker is created while uploading an image to another instance 2024-06-20 09:22:39 +02:00
Andrey Antukh
2982dde7df Merge pull request #4776 from penpot/SudoVanilla-patch-1
🔥 Remove version specification from docker-compose.yaml file
2024-06-20 08:28:04 +02:00
SudoVanilla
acb7ca5440 🔥 Remove version specification from docker-compose.yaml file
It is deprecated
2024-06-20 08:16:02 +02:00
Alejandro
3e6b34c563 Merge pull request #4772 from penpot/niwinz-audit-enhancements-2
 Minor enhancements to audit events related to clone-template
2024-06-20 07:05:37 +02:00
Yaron Shahrabani
8a7fdaa6ca 🌐 Add translations for: Hebrew.
Currently translated at 100.0% (1408 of 1408 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/he/
2024-06-19 22:09:19 +02:00
Stas Haas
27c574f0a7 🌐 Add translations for: German.
Currently translated at 99.5% (1401 of 1408 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/de/
2024-06-19 22:09:18 +02:00
Unreal Vision
6d82d54560 🌐 Add translations for: French.
Currently translated at 96.6% (1361 of 1408 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/fr/
2024-06-19 22:09:17 +02:00
Andrey Antukh
6a253871b0 Improve internal handling of external-session-id 2024-06-19 16:15:48 +02:00
Andrey Antukh
8da153f604 Emit create-file action events on clone-template 2024-06-19 14:58:04 +02:00
Andrey Antukh
d1e9ea372a Assign external session ID to params on RPC main handler 2024-06-19 14:57:17 +02:00
Alejandro Alonso
b668fed1c8 🐛 Export shapes that are rotated act a bit strange when reimported 2024-06-19 13:04:15 +02:00
Andrey Antukh
d527184dfc ♻️ Try to fix recursive update-file ops on text edition
on concurrent multi-user sessions
2024-06-19 11:48:08 +02:00
Andrey Antukh
a2cc7764fb Improve how indexes are updated on concurrent sessions 2024-06-19 11:48:08 +02:00
Alejandro
d977b4e27c Merge pull request #4768 from penpot/eva-visual-testing-viewer
  Add visual testing to viewer
2024-06-19 10:43:46 +02:00
Eva Marco
f3193a1984 Add visual testing to viewer 2024-06-19 10:01:31 +02:00
Alejandro
5e7180b054 Merge pull request #4767 from penpot/ladybenko-ds-visual-tests-workspace-stg
📎 Add (temporary) visual regression tests for the Workspace
2024-06-19 09:55:18 +02:00
Belén Albeza
7f4f54e3fd 📎 Add (temporary) visual regression tests for the Workspace 2024-06-19 09:44:03 +02:00
Alejandro Alonso
cba62c0172 Merge remote-tracking branch 'origin/staging' into develop 2024-06-19 08:12:19 +02:00
Alejandro
8a0aa9cd7f Merge pull request #4760 from penpot/niwinz-fix-json-truncation
🐛 Fix json encoding output truncation
2024-06-19 08:10:48 +02:00
Alejandro Alonso
bc8435dc5b Merge remote-tracking branch 'origin/main' into staging 2024-06-19 08:01:08 +02:00
Andrey Antukh
3363793d64 🐛 Fix json encoding truncation issue 2024-06-19 07:59:28 +02:00
Alejandro
bb63375933 Merge pull request #4764 from penpot/niwinz-audit-enhancements
 Forward external session id to backend
2024-06-19 07:56:11 +02:00
Andrey Antukh
06bab212b5 🐛 Set correct order for http middlewares 2024-06-19 07:48:12 +02:00
Andrey Antukh
504f833a53 🐛 Fix global error handler incorrect body encoding 2024-06-19 07:48:12 +02:00
Andrey Antukh
00b4013385 Forward external session id to backend 2024-06-19 07:45:27 +02:00
Andrés Moya
d039df6b73 Add tests for detach with swapped copies 2024-06-18 23:39:19 +02:00
Alejandro Alonso
47b455ba87 Merge remote-tracking branch 'origin/staging' into develop 2024-06-18 16:57:51 +02:00
Stephan Paternotte
3f29071139 🌐 Add translations for: Dutch.
Currently translated at 100.0% (1408 of 1408 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/nl/
2024-06-18 15:09:24 +02:00
Yaron Shahrabani
ccdfac7b8e 🌐 Add translations for: Hebrew.
Currently translated at 96.2% (1355 of 1408 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/he/
2024-06-18 15:09:23 +02:00
Stas Haas
be959ca90c 🌐 Add translations for: German.
Currently translated at 98.7% (1391 of 1408 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/de/
2024-06-18 15:09:22 +02:00
Alejandro Alonso
3e657874d7 🐛 Create resources/public/css/ on run-devenv 2024-06-18 14:22:48 +02:00
Alejandro
52a49a7359 Merge pull request #4733 from penpot/eva-visual-testing
 Add visual testing to dashboard
2024-06-18 13:16:07 +02:00
Eva Marco
4e770fd326 Add visual testing to dashboard 2024-06-18 10:31:39 +02:00
Aitor Moreno
6023ab1c07 Merge pull request #4746 from penpot/superalex-remove-a-b-testing-for-onboarding-questions
 Remove a/b testing code for onboarding questions
2024-06-18 09:59:18 +02:00
Alejandro
47fcac1c00 Merge pull request #4757 from penpot/niwinz-enhancements-3
 Fix a performance regression with file validation with some features
2024-06-18 09:32:36 +02:00
Andrey Antukh
293b460cab Fix a performance regression with file validation with some features
The feature fdata/pointer-map tracking mechanism interacts pretty bad
with possible local mutations on the validation subsystem. The fix
consist on disabling the tracking mechanism on the validation.
2024-06-17 15:56:06 +02:00
Pablo Alba
4e6c1857dd 🐛 Add validator and repair for duplicated slots on deleted components 2024-06-17 15:15:40 +02:00
Pablo Alba
4546e98dc6 Revert "Revert "🐛 Add validator and repair for duplicated slots""
This reverts commit e0906be6e7.
2024-06-17 15:15:40 +02:00
Brendan Bell
2929783d35 📎 Update docker-compose.yaml 2024-06-17 13:30:51 +02:00
Andrey Antukh
838843be45 Merge branch 'translations' into develop 2024-06-17 10:09:05 +02:00
Anonymous
1225d72917 🌐 Add translations for: Yoruba.
Currently translated at 85.2% (1200 of 1408 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/yo/
2024-06-17 10:07:39 +02:00
Anonymous
9c4a310d84 🌐 Add translations for: Igbo.
Currently translated at 37.1% (523 of 1408 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/ig/
2024-06-17 10:07:39 +02:00
Anonymous
d3e9fd9a36 🌐 Add translations for: Malay.
Currently translated at 48.1% (678 of 1408 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/ms/
2024-06-17 10:07:39 +02:00
Anonymous
d2c63e0857 🌐 Add translations for: Spanish (Latin America).
Currently translated at 9.5% (134 of 1408 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/es_419/
2024-06-17 10:07:39 +02:00
Anonymous
52c00367d7 🌐 Add translations for: Hausa.
Currently translated at 89.9% (1267 of 1408 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/ha/
2024-06-17 10:07:39 +02:00
Anonymous
6ee844b48f 🌐 Add translations for: Afrikaans.
Currently translated at 6.8% (97 of 1408 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/af/
2024-06-17 10:07:39 +02:00
Anonymous
542ad58c32 🌐 Add translations for: Dutch.
Currently translated at 96.7% (1362 of 1408 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/nl/
2024-06-17 10:07:38 +02:00
Anonymous
4781cf1037 🌐 Add translations for: Latvian.
Currently translated at 96.3% (1357 of 1408 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/lv/
2024-06-17 10:07:38 +02:00
Anonymous
5aa3b432bf 🌐 Add translations for: Korean.
Currently translated at 15.5% (219 of 1408 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/ko/
2024-06-17 10:07:38 +02:00
Anonymous
47401aae99 🌐 Add translations for: Bengali.
Currently translated at 1.0% (15 of 1408 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/bn/
2024-06-17 10:07:37 +02:00
Anonymous
27473003b7 🌐 Add translations for: Faroese.
Currently translated at 11.2% (159 of 1408 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/fo/
2024-06-17 10:07:37 +02:00
Anonymous
fa8bc7d40d 🌐 Add translations for: Ukrainian (ukr_UA).
Currently translated at 14.9% (210 of 1408 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/ukr_UA/
2024-06-17 10:07:37 +02:00
Anonymous
f352cdf9a3 🌐 Add translations for: Croatian.
Currently translated at 72.2% (1017 of 1408 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/hr/
2024-06-17 10:07:37 +02:00
Anonymous
3d68d454fe 🌐 Add translations for: Tamil.
Currently translated at 3.2% (46 of 1408 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/ta/
2024-06-17 10:07:37 +02:00
Anonymous
9a9eca7813 🌐 Add translations for: Portuguese (Portugal).
Currently translated at 94.6% (1332 of 1408 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/pt_PT/
2024-06-17 10:07:36 +02:00
Anonymous
f3d82c915b 🌐 Add translations for: Finnish.
Currently translated at 3.9% (55 of 1408 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/fi/
2024-06-17 10:07:36 +02:00
Anonymous
5185d1eaa5 🌐 Add translations for: Czech.
Currently translated at 92.8% (1307 of 1408 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/cs/
2024-06-17 10:07:36 +02:00
Anonymous
6abf792e0f 🌐 Add translations for: Basque.
Currently translated at 83.4% (1175 of 1408 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/eu/
2024-06-17 10:07:36 +02:00
Anonymous
4d56f86719 🌐 Add translations for: Japanese.
Currently translated at 16.6% (235 of 1408 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/ja/
2024-06-17 10:07:35 +02:00
Anonymous
f033814f96 🌐 Add translations for: Galician.
Currently translated at 26.7% (376 of 1408 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/gl/
2024-06-17 10:07:35 +02:00
Anonymous
2e3dbfeb27 🌐 Add translations for: Lithuanian.
Currently translated at 8.4% (119 of 1408 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/lt/
2024-06-17 10:07:35 +02:00
Anonymous
a50e431c7a 🌐 Add translations for: Polish.
Currently translated at 81.3% (1146 of 1408 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/pl/
2024-06-17 10:07:35 +02:00
Anonymous
59e18e8d4c 🌐 Add translations for: Italian.
Currently translated at 32.2% (454 of 1408 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/it/
2024-06-17 10:07:34 +02:00
Anonymous
731299fe60 🌐 Add translations for: Persian.
Currently translated at 47.8% (674 of 1408 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/fa/
2024-06-17 10:07:34 +02:00
Anonymous
5cb2c1bbe4 🌐 Add translations for: Malayalam.
Currently translated at 3.7% (53 of 1408 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/ml/
2024-06-17 10:07:34 +02:00
Anonymous
5362d9f5e9 🌐 Add translations for: Chinese (Traditional).
Currently translated at 45.8% (646 of 1408 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/zh_Hant/
2024-06-17 10:07:34 +02:00
Anonymous
981cd92b26 🌐 Add translations for: Hebrew.
Currently translated at 96.0% (1353 of 1408 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/he/
2024-06-17 10:07:34 +02:00
Anonymous
77b70cac60 🌐 Add translations for: Indonesian.
Currently translated at 96.0% (1352 of 1408 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/id/
2024-06-17 10:07:33 +02:00
Anonymous
ac8775565b 🌐 Add translations for: Arabic.
Currently translated at 80.0% (1127 of 1408 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/ar/
2024-06-17 10:07:33 +02:00
Anonymous
5651b72c0f 🌐 Add translations for: Romanian.
Currently translated at 90.0% (1268 of 1408 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/ro/
2024-06-17 10:07:33 +02:00
Anonymous
3e54ab1c3c 🌐 Add translations for: Danish.
Currently translated at 7.4% (105 of 1408 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/da/
2024-06-17 10:07:33 +02:00
Anonymous
81482c8350 🌐 Add translations for: German.
Currently translated at 97.0% (1367 of 1408 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/de/
2024-06-17 10:07:32 +02:00
Anonymous
9f25c6eb09 🌐 Add translations for: Portuguese (Brazil).
Currently translated at 81.3% (1145 of 1408 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/pt_BR/
2024-06-17 10:07:32 +02:00
Anonymous
4d778e71fe 🌐 Add translations for: Chinese (Simplified).
Currently translated at 95.8% (1349 of 1408 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/zh_Hans/
2024-06-17 10:07:32 +02:00
Anonymous
36d0e6eb36 🌐 Add translations for: Turkish.
Currently translated at 97.1% (1368 of 1408 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/tr/
2024-06-17 10:07:32 +02:00
Anonymous
492a975a3a 🌐 Add translations for: Russian.
Currently translated at 56.1% (790 of 1408 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/ru/
2024-06-17 10:07:31 +02:00
Anonymous
ac14a6315b 🌐 Add translations for: Greek.
Currently translated at 36.9% (520 of 1408 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/el/
2024-06-17 10:07:31 +02:00
Anonymous
37abe7d7f1 🌐 Add translations for: French.
Currently translated at 96.3% (1356 of 1408 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/fr/
2024-06-17 10:07:31 +02:00
Anonymous
0cebd89c01 🌐 Add translations for: Catalan.
Currently translated at 75.0% (1057 of 1408 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/ca/
2024-06-17 10:07:30 +02:00
Hosted Weblate
2f49b419bd Update translation files
Updated by "Cleanup translation files" hook in Weblate.

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/
2024-06-17 10:02:54 +02:00
Stephan Paternotte
c144a20012 🌐 Add translations for: Dutch.
Currently translated at 100.0% (1390 of 1390 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/nl/
2024-06-17 10:02:52 +02:00
Stas Haas
1cf79fb56e 🌐 Add translations for: German.
Currently translated at 99.9% (1389 of 1390 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/de/
2024-06-17 10:02:52 +02:00
Oğuz Ersen
68724e6236 🌐 Add translations for: Turkish.
Currently translated at 100.0% (1390 of 1390 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/tr/
2024-06-17 10:02:52 +02:00
Andrey Antukh
f529b339c6 Merge remote-tracking branch 'origin/staging' into develop 2024-06-17 10:02:34 +02:00
Andrés Moya
e0906be6e7 Revert "🐛 Add validator and repair for duplicated slots"
This reverts commit db2ba42b14.
2024-06-17 09:56:27 +02:00
Pablo Alba
db2ba42b14 🐛 Add validator and repair for duplicated slots 2024-06-17 09:23:50 +02:00
Alejandro
1d28be07d0 Merge pull request #4747 from penpot/niwinz-bugfix-2
🔥 Fix many inconsistencies on the onboarding translation strings
2024-06-17 06:58:23 +02:00
Pablo Alba
cc1b51cb2c Add fix to locate files with duplicated slots 2024-06-14 13:57:30 +02:00
Aitor Moreno
22ede6b08e Merge pull request #4731 from penpot/niwinz-bugfix-6
🐛 Fix many race conditions on thumbnail generation process
2024-06-14 13:15:10 +02:00
Andrey Antukh
a3ac22f781 🔥 Fix many inconsistencies on the onboarding translation strings
Mainly related to the quiestions modal
2024-06-14 11:55:57 +02:00
Pablo Alba
2d9c5d1ac4 Merge pull request #4742 from penpot/hiru-fix-detach-swapped-nested
Fix detach swapped nested
2024-06-14 11:04:41 +02:00
Andrés Moya
1ac6b556b0 🐛 Fix detach when a nested copy has been swapped 2024-06-14 10:45:42 +02:00
Andrés Moya
b5477c4e30 🔧 Improve debug utility 2024-06-14 10:45:20 +02:00
Alejandro Alonso
b991391667 Merge remote-tracking branch 'origin/staging' into develop 2024-06-14 08:10:51 +02:00
Alejandro
7a05580df3 Merge pull request #4745 from penpot/niwinz-bugfix-9
🐛 Clear persistence status on server error
2024-06-14 08:10:11 +02:00
Alejandro Alonso
2c506fc721 🐛 Fix SVG attrs are not handled correctly when exporting/importing .zip 2024-06-14 07:58:18 +02:00
Alejandro Alonso
043769c255 Remove a/b testing code for onboarding questions 2024-06-14 07:45:59 +02:00
Andrey Antukh
88540eeedd Merge remote-tracking branch 'origin/staging' into develop 2024-06-14 07:45:53 +02:00
Alejandro
68741bb56f Merge pull request #4744 from penpot/niwinz-bugfix-8
 Fix translation strings inconsistencies on the onboarding questions modals
2024-06-14 07:00:56 +02:00
Alejandro Alonso
0d23f4ab5d 🐛 Workspace-palette items stay hidden when opening with keyboard-shortcut 2024-06-14 00:06:08 +02:00
Belén Albeza
599bc8dbe7 📎 Remove unused playwright config file in root 2024-06-14 00:05:13 +02:00
Andrey Antukh
f463a1989f 🐛 Clear persistence status on server error
This avoids the problem of permanently keeping on the persistence
queue a problematic change.
2024-06-14 00:01:59 +02:00
Andrey Antukh
a9f5b1559f Make translations consistent on the onboarding questions modal 2024-06-13 23:51:23 +02:00
Andrey Antukh
b4c9528603 Add missing frontend translations to devenv watcher 2024-06-13 18:01:46 +02:00
Eva Marco
a84c2e1138 Merge pull request #4741 from penpot/superalex-fix-persistence-status-widget-color
🐛 Fix persistence status widget lost saving status color
2024-06-13 16:11:53 +02:00
Alejandro Alonso
1ad2171933 🐛 Fix persistence status widget lost saving status color 2024-06-13 14:47:42 +02:00
Eva Marco
195305e4c8 Merge pull request #4737 from penpot/niwinz-bugfix-7
🐛 Fix onboarding step1 values
2024-06-13 13:05:05 +02:00
Andrey Antukh
535246f1c6 🐛 Fix onboarding step1 values 2024-06-13 12:45:36 +02:00
Alejandro Alonso
7e87362a39 Merge remote-tracking branch 'origin/staging' into develop 2024-06-13 11:04:58 +02:00
Alejandro
1a7cdfbf56 Merge pull request #4734 from penpot/superalex-cherry-picking
 Cherry-pick
2024-06-13 10:58:38 +02:00
alonso.torres
d48e486668 🐛 Fix problem moving layout to frame 2024-06-13 10:47:22 +02:00
Alejandro Alonso
c15c3b14ee Add e2e tests for fix color palette default library 2024-06-13 10:47:22 +02:00
Alejandro
5c1e7adf7e Merge pull request #4724 from penpot/palba-fix-open-overlay-self
🐛 Fix open overlay relative to a frame
2024-06-13 06:34:14 +02:00
Pablo Alba
67e1081f11 🐛 Fix open overlay relative to a frame 2024-06-13 06:33:48 +02:00
Alejandro
dd69f8f29b Merge pull request #4727 from penpot/eva-fix-scroll-select
🐛 Fix move scrollbar create a selection rectangle
2024-06-13 06:28:40 +02:00
Eva Marco
232cfea709 🐛 Fix move scrollbar create a selection rectangle 2024-06-13 06:28:26 +02:00
Alejandro
09a671cffa Merge pull request #4730 from penpot/azazeln28-fix-toolbar-keeps-hiding-clicking-outside
🐛 Fix toolbar keeps hiding clicking outside
2024-06-12 17:07:56 +02:00
AzazelN28
b4004af255 🐛 Fix toolbar keeps hiding when clicking outside 2024-06-12 17:07:35 +02:00
Aitor Moreno
a150e1c2e5 Merge pull request #4728 from penpot/superalex-toolbar-keeps-toggling-on-and-off
🐛 Toolbar keeps toggling on and off on spacebar press
2024-06-12 17:05:30 +02:00
Alejandro Alonso
740a872231 🐛 Toolbar keeps toggling on and off on spacebar press 2024-06-12 16:41:06 +02:00
Andrey Antukh
ec7aa64c62 Disable http cache from get-file-object-thumbnails RPC method 2024-06-12 16:13:34 +02:00
Andrey Antukh
c1463ebd12 🐛 Fix many race conditions on thumbnail generation process 2024-06-12 16:04:08 +02:00
Alejandro Alonso
bbd9207191 Improve email verify threshold 2024-06-12 13:56:19 +02:00
Alejandro
82a5754923 Merge pull request #4729 from penpot/hiru-fix-detach-slots
🐛 Fix swap slots when detaching a copy with subcopies
2024-06-12 13:54:31 +02:00
Andrés Moya
03aa0817f7 🐛 Fix swap slots when detaching a copy with subcopies 2024-06-12 13:17:17 +02:00
Alejandro Alonso
058a72b817 🐛 Fix internal error when I set up a stroke for some objects without and with stroke 2024-06-12 13:00:39 +02:00
Alejandro Alonso
9f7a002a78 🐛 Fix misaligned input on comments 2024-06-12 10:20:18 +02:00
Alejandro Alonso
a861691ffd 🐛 Fix change color on imported svg also changes the stroke alignment 2024-06-12 10:08:30 +02:00
Alejandro Alonso
a5ba9d113f Improve create group tests 2024-06-12 10:07:34 +02:00
Alejandro
132908c224 Merge pull request #4723 from penpot/ladybenko-7466-layers-sidebar
Fix layers tree not expanding to the bottom edge
2024-06-12 09:36:47 +02:00
Belén Albeza
f417445f31 Refactor WorkspacePage so it has more semantic locators 2024-06-12 09:23:30 +02:00
Belén Albeza
7719cd8d0b ♻️ Move libraries test to sidebar spec file 2024-06-12 09:23:30 +02:00
Belén Albeza
04f341ce1d 🐛 Fix layers tree not expanding towards the bottom edge 2024-06-12 09:23:30 +02:00
Alejandro
00f7ea2b56 Merge pull request #4720 from penpot/niwinz-bugfix-5
 Improve how email is passed on post-signup page
2024-06-12 09:00:29 +02:00
Alejandro
f2cc363caa Merge pull request #4698 from penpot/eva-new-onboarding-integration-tests
 Add integration tests to new onboarding process
2024-06-12 08:57:17 +02:00
Eva Marco
a90baa91c7 Add integration test to the onboarding process 2024-06-11 16:35:05 +02:00
Belén Albeza
c6da42ee35 Merge pull request #4721 from penpot/alotor-bugfix
🐛 Fix problem moving layout to frame
2024-06-11 15:06:08 +02:00
alonso.torres
f88bb4e204 🐛 Fix problem moving layout to frame 2024-06-11 14:55:00 +02:00
Andrey Antukh
4057084981 Improve how email is passed on post-signup page 2024-06-11 14:12:07 +02:00
Alejandro
8f42be1096 Merge pull request #4710 from penpot/eva-fix-guides
🐛 Fix move guides with board
2024-06-11 14:06:34 +02:00
Alejandro
27d8d8649e Merge pull request #4718 from penpot/niwinz-bugfix-4
 Add minor improvements on how we handle logout
2024-06-11 14:02:19 +02:00
Alejandro
136b115006 Merge pull request #4717 from penpot/niwinz-bugfix-3
🐛 Fix issue with annotation menu rerendering
2024-06-11 13:55:28 +02:00
Eva Marco
0e0ceaa9bf 🐛 Fix move guides with board 2024-06-11 12:54:43 +02:00
Andrey Antukh
c0919aff51 Merge remote-tracking branch 'origin/staging' into develop 2024-06-11 11:27:16 +02:00
Andrey Antukh
eba6f51953 📎 Update THANKYOU.md file 2024-06-11 11:03:54 +02:00
Andrey Antukh
c14f6aecf3 📎 Update THANKYOU.md file 2024-06-11 11:03:54 +02:00
Andrey Antukh
6896a4e9f0 Add minor improvements on how logout is handled
The profile-id is now required on the body of logout request
2024-06-11 11:03:54 +02:00
Pablo Alba
8825e9f80b 🐛 Fix show in view mode and interactions workflow 2024-06-11 11:01:24 +02:00
Alejandro Alonso
694e71c3fc Improve CHANGES.md format 2024-06-11 10:54:11 +02:00
Alejandro Alonso
46764a1e6e 🐛 Fix export boards loses opacity 2024-06-11 10:54:11 +02:00
Alejandro Alonso
3d7f399a50 🐛 Fix missing scroll in comments 2024-06-11 10:38:41 +02:00
Alejandro Alonso
c5bf2a775e 🐛 Fix group automatically selected after creation 2024-06-11 10:38:03 +02:00
Andrey Antukh
2d527b2caf 🐛 Fix issue with annotation menu rerendering 2024-06-11 10:29:26 +02:00
Alejandro
38fa5be862 Merge pull request #4653 from penpot/eva-new-onboarding-modals
 Update onboarding modals
2024-06-11 10:19:26 +02:00
Andrey Antukh
93ac80f217 Improve onboarding initialization 2024-06-11 09:47:03 +02:00
Alejandro Alonso
3bb5db6490 Merge remote-tracking branch 'origin/staging' into develop 2024-06-11 07:34:48 +02:00
Alejandro
88e2e11634 Merge pull request #4713 from penpot/hiru-bugs-export-zip
Fix bugs in the export to zip file
2024-06-11 07:33:01 +02:00
Alejandro
4db189f90d Merge pull request #4714 from penpot/niwinz-persistence-bugfix-1
🐛 Fix race condition between shape modifiation and persistence
2024-06-11 07:26:02 +02:00
Andrey Antukh
d35569dc55 Simplify transducer definition for proces redo changes 2024-06-10 18:59:39 +02:00
Andrey Antukh
e4e56828f6 💄 Fix internal naming for make code more self-explanatory 2024-06-10 18:56:59 +02:00
Andrey Antukh
3c1086dfcc 🐛 Fix race condition between shape modifiation and persistence 2024-06-10 18:51:48 +02:00
Andrey Antukh
b635427f91 🐛 Fix incorrect order of update-index operations 2024-06-10 17:50:46 +02:00
Andrés Moya
9a4c45c8a3 🐛 Fix export touched attributes 2024-06-10 17:09:46 +02:00
alonso.torres
33166032f1 ⬆️ Update plugins runtime 2024-06-10 15:12:51 +02:00
alonso.torres
5233654da2 Add support for plugin data into penpot objects 2024-06-10 15:12:51 +02:00
alonso.torres
4d4a3a512d 💄 Style changes to the plugins modal 2024-06-10 15:12:51 +02:00
alonso.torres
411fe5448b 🐛 Fix rename layers for plugins 2024-06-10 15:12:51 +02:00
Andrey Antukh
273a5f7a0a Improve state management on onboarding team modal 2024-06-10 14:36:25 +02:00
Andrey Antukh
0dda893d73 Improve state management on onboarding newsletter modal 2024-06-10 14:36:25 +02:00
Andrey Antukh
2629fa0662 Improve state management on onboarding questions modal 2024-06-10 14:36:24 +02:00
Eva Marco
fda6deaa4f Update onboarding modals 2024-06-10 14:36:24 +02:00
Andrey Antukh
55ce9bef49 🐛 Fix incorrect error merging mechanism on form validation 2024-06-10 14:36:24 +02:00
Andrey Antukh
e7a8c25883 🐛 Fix touched handling on multi-input form component 2024-06-10 14:36:24 +02:00
Andrey Antukh
88b65cd864 🐛 Fix incorrect compilation of css-case macro in a small corne case 2024-06-10 14:36:24 +02:00
Andrés Moya
257dab4775 🐛 Fix export hidden shapes 2024-06-10 11:09:14 +02:00
Alejandro Alonso
edfc47d3de Add e2e tests for fix color palette default library 2024-06-10 09:29:58 +02:00
Alejandro
d8184fb756 Merge pull request #4703 from penpot/palba-bugfixing-009
Palba bugfixing 009
2024-06-10 06:45:47 +02:00
Pablo Alba
96993a6ebd 🐛 Fix "Share prototypes" modal remains open 2024-06-10 06:45:29 +02:00
Pablo Alba
1f7b5a0f7f 🐛 Fix black line is displaying after show main 2024-06-10 06:45:27 +02:00
Alejandro
a553de3c98 Merge pull request #4699 from penpot/ladybenko-7805-viewer-zoom
Fix zoom setting not updating the URL in viewer
2024-06-10 06:40:02 +02:00
Pablo Alba
d9618c6213 Merge pull request #4700 from penpot/alotor-bugfix
Alotor bugfix
2024-06-07 16:33:41 +02:00
alonso.torres
3ad91d1c9d 🐛 Fix problem with flex layout fit to content not positioning correctly children 2024-06-07 15:25:57 +02:00
alonso.torres
2c21a049e1 🐛 Fix problem with moving+selection not working properly 2024-06-07 14:04:03 +02:00
Belén Albeza
724bc24063 Add test for #7805 2024-06-07 13:44:54 +02:00
Belén Albeza
96b7fb7f12 🐛 Fix viewer querystring not being updated with zoom type 2024-06-07 13:15:20 +02:00
Pablo Alba
f052c81ee1 🐛 Fix issue with annotation menu rerendering (2) 2024-06-07 13:08:43 +02:00
Pablo Alba
b170a619cd Merge pull request #4695 from penpot/niwinz-bugfix-annotations
🐛 Fix issue with annotation menu rerendering
2024-06-07 13:06:40 +02:00
Alejandro
d29215a282 Merge pull request #4675 from penpot/niwinz-enhancements-1
 Add backward compatibility fixes for email whitelisting
2024-06-07 13:04:34 +02:00
Andrey Antukh
4d2f82e03a 🐛 Fix issue with annotation menu rerendering 2024-06-07 12:55:33 +02:00
alonso.torres
da738ba1e9 Merge remote-tracking branch 'origin/staging' into develop 2024-06-07 12:21:57 +02:00
Andrey Antukh
ae90d59b43 Remove spec usage o teams rpc ns 2024-06-07 10:30:14 +02:00
Andrey Antukh
046ef7eb6e 🔥 Replace clojure.spec with simple assert on tokens ns 2024-06-07 10:30:14 +02:00
Andrey Antukh
25265cec70 Remove claims from token validation error report 2024-06-07 10:30:14 +02:00
Andrey Antukh
40f39681ad Add backward compatibility fixes for email whitelisting 2024-06-07 10:30:14 +02:00
Alejandro
70c9314f7f Merge pull request #4685 from penpot/palba-fix-validation-error-coping-main-frame
🐛 Fix verification error on coping main component with frame over a copy
2024-06-07 09:59:39 +02:00
Alejandro
7bf4305269 Merge pull request #4682 from penpot/ladybenko-7686-mixed-constraints
Fix constraints dropdown not showing "Mixed"
2024-06-07 07:44:04 +02:00
Alejandro
49879caf2c Merge pull request #4691 from penpot/alotor-fix-components
Alotor fix components
2024-06-07 07:40:26 +02:00
alonso.torres
33bf8892c0 🐛 Fix problem when creating multiple components 2024-06-06 17:17:01 +02:00
Belén Albeza
4efab3e8c8 Add an integration test for #7686 (constraints dropdown) 2024-06-06 15:30:21 +02:00
Belén Albeza
c8ff8fcbf7 🐛 Fix multiple constraints dropdown not showing 'mixed' 2024-06-06 15:29:28 +02:00
Belén Albeza
2f84978274 Merge pull request #4687 from penpot/superalex-e2e-tests-color-palette
 Add e2e tests for fix color palette default library
2024-06-06 15:27:48 +02:00
Belén Albeza
da40d662be Merge pull request #4684 from penpot/superalex-speed-up-e2e-testing
 Speed up e2e testing
2024-06-06 15:13:07 +02:00
Andrey Antukh
1d88c7e92d ⬆️ Upgrade devenv linux distribution version
We pass from ubuntu 22.04 LTS to Debian 12 (bookworm)
Update postgresql from 15 to 16
Update JVM21 to the latest minor version
2024-06-06 15:06:16 +02:00
Alejandro
1a312b08b7 Merge pull request #4676 from penpot/ladybenko-7988-fix-viewer-logo
🐛 Fix link in penpot logo spanning way below it (in viewer)
2024-06-06 13:06:47 +02:00
Alejandro Alonso
08c3901134 Speed up e2e testing 2024-06-06 13:04:27 +02:00
Alejandro Alonso
5af9bb1cdb Add e2e tests for fix color palette default library 2024-06-06 12:54:31 +02:00
Andrey Antukh
c8130e9453 Send profile zoom and vport/vbox on presence notifications 2024-06-06 12:02:43 +02:00
Andrés Moya
ccd687cbf3 Merge branch 'staging' into develop 2024-06-06 11:21:42 +02:00
Andrés Moya
bc3aac1597 📖 Update change log 2024-06-06 10:29:11 +02:00
Andrés Moya
41024728ae 🐛 Fix importing a component from a zip file in v2 2024-06-06 10:29:11 +02:00
Pablo Alba
91fd8c4f81 🐛 Fix verror on coping main component with frame over a copy 2024-06-06 10:24:39 +02:00
Belén Albeza
67ababf1ed 🐛 Fix link in penpot logo spanning way below it (in viewer) 2024-06-06 09:30:52 +02:00
Belén Albeza
2aa1b97769 Merge pull request #4678 from penpot/superalex-bugfixing
🐛 Bugfixing
2024-06-05 14:11:36 +02:00
Alejandro Alonso
ca73a79cfe 📎 Prepare new development cycle 2024-06-05 12:46:11 +02:00
Anonymous
4e0c6f847f 🌐 Add translations for: Yoruba.
Currently translated at 87.7% (1220 of 1390 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/yo/
2024-06-05 12:42:53 +02:00
Anonymous
ee2f4c11c0 🌐 Add translations for: Igbo.
Currently translated at 38.9% (542 of 1390 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/ig/
2024-06-05 12:42:53 +02:00
Anonymous
5814559880 🌐 Add translations for: Hausa.
Currently translated at 92.5% (1287 of 1390 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/ha/
2024-06-05 12:42:53 +02:00
Anonymous
2569282d91 🌐 Add translations for: Korean.
Currently translated at 16.0% (223 of 1390 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/ko/
2024-06-05 12:42:53 +02:00
Anonymous
8f5a35f5f9 🌐 Add translations for: German.
Currently translated at 99.1% (1378 of 1390 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/de/
2024-06-05 12:42:53 +02:00
Anonymous
7971bcf7d9 🌐 Add translations for: Chinese (Simplified).
Currently translated at 98.5% (1370 of 1390 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/zh_Hans/
2024-06-05 12:42:52 +02:00
Andrey Antukh
64a5c68cc9 Merge branch 'translations' into develop 2024-06-05 12:41:12 +02:00
Andrey Antukh
028812dc10 Merge remote-tracking branch 'weblate/develop' into translations 2024-06-05 12:40:07 +02:00
Alejandro Alonso
5eee1cdbf3 Merge remote-tracking branch 'origin/staging' 2024-06-05 12:26:23 +02:00
Alejandro Alonso
fc7294c10d Make CHANGES format uniform 2024-06-05 09:37:53 +02:00
Alejandro Alonso
697b6776ba 🐛 Fix color palette default library 2024-06-05 06:38:22 +02:00
alonso.torres
3a40c7f59c ⬆️ Update plugin runtime 2024-06-04 16:44:24 +02:00
alonso.torres
3e2ccbc85f Add infor for users 2024-06-04 16:44:24 +02:00
alonso.torres
98c550b20e Update content of path shapes in plugins 2024-06-04 16:44:24 +02:00
alonso.torres
bf66e12075 Allow masks, booleans, and some path read only 2024-06-04 16:44:24 +02:00
alonso.torres
55c27f140a Create paths, booleans and ellipses through plugins api 2024-06-04 16:44:24 +02:00
alonso.torres
e4e537b960 Add support for components in plugins 2024-06-04 16:44:24 +02:00
alonso.torres
3209511557 Add support for colors and typographies 2024-06-04 16:44:24 +02:00
Alejandro
d4a0541926 Merge pull request #4670 from penpot/niwinz-email-shortening
 Abbreviate profile name on emails
2024-06-04 13:01:35 +02:00
Pablo Alba
5872bf024c Add test for remove swap slot on detach parent 2024-06-04 12:24:31 +02:00
Pablo Alba
5b88589157 Merge remote-tracking branch 'origin/staging' into develop 2024-06-04 11:57:59 +02:00
Andrey Antukh
b6b6822c31 Abbreviate profile name on emails 2024-06-04 11:32:28 +02:00
Alejandro
622d1faffc Merge pull request #4664 from penpot/niwinz-email-blacklist
 Add email blacklist mechanism
2024-06-04 11:18:28 +02:00
Pablo Alba
54c506100d 🐛 Fix swap slot is not removed on parent detach (2) 2024-06-04 11:17:06 +02:00
Andrey Antukh
5aa62ef1dd Add email blacklist mechanism 2024-06-04 10:45:55 +02:00
Alejandro
83090826f7 Merge pull request #4463 from penpot/niwinz-workspace-persistence-3
♻️ Refactor frontend persistence layer
2024-06-04 10:38:37 +02:00
Pablo Alba
7c64ed84f1 🐛 Fix swap slot is not removed on parent detach 2024-06-04 10:20:26 +02:00
Andrey Antukh
6436ef334b ♻️ Refactor persistence layer 2024-06-04 10:15:32 +02:00
Alejandro
5fef0b64f4 Merge pull request #4665 from penpot/niwinz-sanitize-audit
 Add stricter validation for audit events
2024-06-04 10:12:27 +02:00
Andrey Antukh
3294058e16 Add stricter validation for audit events 2024-06-04 09:54:41 +02:00
Alejandro
d679001955 Merge pull request #4663 from penpot/eva-bugfixing-2.1
🐛 Bugfixing
2024-06-04 09:54:29 +02:00
Eva Marco
b74c5fc9b3 🐛 Fix demo account visible on login 2024-06-04 09:39:18 +02:00
Eva Marco
f9692fde35 Allow library colors as recent colors 2024-06-04 09:39:15 +02:00
Eva Marco
53526b9957 🐛 Fix expand libraries when search results are present 2024-06-04 09:38:36 +02:00
Alejandro
38353f3728 Merge pull request #4660 from penpot/niwinz-update-deps
⬆️ Update dependencies
2024-06-04 09:37:00 +02:00
Eva Marco
ee2ee326f3 Merge pull request #4662 from penpot/superalex-locking-degrees-on-path-edition
 Add locking degrees increment (hold shift) on path edition
2024-06-04 09:34:54 +02:00
Alejandro
fabe2d3d1d Merge pull request #4666 from penpot/ladybenko-7559-fix-palette
Fixes for the color palette
2024-06-04 09:27:59 +02:00
Belén Albeza
f8ca4c4343 🐛 Fix color name in circle bullets spanning over more than 2 lines 2024-06-04 09:08:59 +02:00
Belén Albeza
258aaf81d5 🐛 Fix color palette inner scroll width 2024-06-04 09:05:34 +02:00
Belén Albeza
8f0fd0a6e2 🐛 Fix wrong css selector applied globally and affecting the palette 2024-06-04 09:05:34 +02:00
Belén Albeza
de7880b4a2 🐛 Fix color names in palette being clipped and not breaking at dot characters 2024-06-04 09:05:34 +02:00
Pablo Alba
06221c37a3 Update THANKYOU.md 2024-06-04 09:05:34 +02:00
Alejandro Alonso
e200ed616c 🎉 Add a/b test for onboarding questions 2024-06-04 09:05:34 +02:00
Andrés Moya
5e8c164a44 🐛 Add migration to remove all misplaced slots 2024-06-03 17:17:14 +02:00
Andrés Moya
3472359168 🐛 Add validate and repair for :misplaced-slot 2024-06-03 17:17:02 +02:00
Pablo Alba
928fec0903 Merge pull request #4661 from penpot/hiru-improve-slot-validation
🐛 Add validate and repair for :misplaced-slot
2024-06-03 16:08:54 +02:00
Pablo Alba
53513a523e Update THANKYOU.md 2024-06-03 13:04:49 +02:00
Alejandro Alonso
b5c419512f Add locking degrees increment (hold shift) on path edition 2024-06-03 13:01:45 +02:00
Andrés Moya
21052c661c 🐛 Add migration to remove all misplaced slots 2024-06-03 11:37:13 +02:00
Andrés Moya
b700a926c2 🐛 Add validate and repair for :misplaced-slot 2024-06-03 10:55:29 +02:00
Andrey Antukh
3bdcaa12e7 ⬆️ Update AWS S3 SDK dependency on backend 2024-05-31 13:31:56 +02:00
Andrey Antukh
87e3dc1c7c ⬆️ Update dependencies across all modules 2024-05-31 13:28:32 +02:00
Andrey Antukh
76ca1d9be8 ⬆️ Update frontend npm dependencies 2024-05-31 12:59:11 +02:00
Andrey Antukh
e2dd6a3791 ⬆️ Update playwright 2024-05-31 12:34:07 +02:00
Andrey Antukh
1d7c7f4a72 ⬆️ Update react to 18.3.1 2024-05-31 11:57:38 +02:00
Andrey Antukh
3c3ef57da2 Merge remote-tracking branch 'origin/staging' into develop 2024-05-31 10:08:21 +02:00
Aitor Moreno
1b17742fc3 Merge pull request #4654 from penpot/superalex-a-b-test-onboarding-questions
🎉 Add a/b test for onboarding questions
2024-05-31 09:50:00 +02:00
Alejandro Alonso
98038b10a0 🎉 Add a/b test for onboarding questions 2024-05-30 14:54:40 +02:00
Alejandro Alonso
91ca55742a Merge remote-tracking branch 'origin/staging' 2024-05-30 12:00:03 +02:00
alonso.torres
98f3ef2755 ⬆️ Update plugins runtime 2024-05-30 10:11:15 +02:00
alonso.torres
ae774b10be Removed mandatory manifest property 2024-05-30 10:11:15 +02:00
Andrey Antukh
4bd585739a Merge branch 'mbiesiad-develop' into develop 2024-05-30 00:10:54 +02:00
Michal
9646f13a22 📚 Fix markdown bugs on changelog
Fix Markdown :bug
2024-05-30 00:10:37 +02:00
Andrés Moya
83327ef278 🔧 Change backend test runner to kaocha 2024-05-29 19:05:04 +02:00
Andrés Moya
0a3a6e19f1 Add test for swap slots bug 2024-05-29 15:12:19 +02:00
Andrés Moya
81ea392da6 Merge branch 'staging' into develop 2024-05-29 15:10:44 +02:00
Andrés Moya
e83c90203e 🐛 Migration to remove bad swap-slots 2024-05-29 15:09:04 +02:00
Pablo Alba
b4a7a15045 Revert "🐛 swap slot is not copied on copy-paste of a main"
This reverts commit 2a752e3625.
2024-05-29 15:09:04 +02:00
Alejandro Alonso
b847754e3b Support external feature flags 2024-05-29 13:18:47 +02:00
alonso.torres
007ab3d909 Add library edition mode for plugins 2024-05-29 12:54:49 +02:00
Belén Albeza
b95cb3d4c5 Merge pull request #4638 from penpot/ladybenko-7936-setup-temp-visual-testing
 Setup temporary visual regression testing for the design system
2024-05-29 09:28:53 +02:00
Belén Albeza
804f4bb176 🐛 Fix color picker position 2024-05-28 20:54:50 +02:00
alonso.torres
d073f51790 🐛 Fix problem with plugin edition text 2024-05-28 20:54:11 +02:00
Alejandro
9c5f7373de Merge pull request #4641 from penpot/hiru-validate-swap-slots
🔧 Add temporary validation to catch a bug
2024-05-28 16:33:10 +02:00
Andrés Moya
3e8c665b7f 🔧 Add optional validation to check missing swap slots 2024-05-28 16:19:30 +02:00
Belén Albeza
d4dc87a740 Setup temporary visual regression testing for the design system 2024-05-28 14:54:26 +02:00
alonso.torres
a2df74be38 Improved styles for plugins dialog 2024-05-28 13:44:39 +02:00
alonso.torres
032e551dc1 🐛 Fix problem with shadows 2024-05-28 13:44:39 +02:00
Alejandro Alonso
dad91421b1 📚 Update changelog 2024-05-28 11:27:18 +02:00
Alejandro Alonso
4ee9272177 Merge remote-tracking branch 'origin/staging' into develop 2024-05-28 10:43:00 +02:00
Alejandro Alonso
cf6bea1974 Merge remote-tracking branch 'origin/staging' 2024-05-28 10:42:30 +02:00
Alejandro Alonso
b8bff31aca 📎 Increase version 2024-05-28 10:42:01 +02:00
Alejandro Alonso
6d8fe193fb Merge remote-tracking branch 'origin/staging' into develop 2024-05-28 08:14:20 +02:00
Alejandro Alonso
54c4e9af6c Merge remote-tracking branch 'origin/staging' 2024-05-28 08:10:21 +02:00
Alejandro Alonso
07d859f9bd 🐛 Fix penpot.app links 2024-05-28 08:08:53 +02:00
Alejandro
c918e06859 Merge pull request #4636 from penpot/niwinz-bugfix-2
 Minor changes
2024-05-28 08:07:46 +02:00
alonso.torres
313e501a2a Expose text properties for shapes 2024-05-28 08:04:06 +02:00
alonso.torres
9498006fb8 🐛 Fix problem with border radius 2024-05-28 08:04:06 +02:00
alonso.torres
0576884a8b 🐛 Fix problem when setting shadows/blurs 2024-05-28 08:04:06 +02:00
alonso.torres
f0427e454e Add default icon for plugins 2024-05-28 08:04:06 +02:00
Alejandro
0b8604f9ea Merge pull request #4633 from penpot/niwinz-objects-gc-locking
 Improve object deletion flow
2024-05-27 16:20:50 +02:00
Andrey Antukh
121bff4eac Send only necessary data on profile update 2024-05-27 16:06:27 +02:00
Andrey Antukh
408ca338e7 📎 Make public default profile audit props 2024-05-27 16:06:27 +02:00
Alejandro
d008d82a11 Merge pull request #4634 from penpot/niwinz-xdomain-cookie
 Improve auth-data xdomain cookie
2024-05-27 11:34:58 +02:00
Andrey Antukh
574c8d1789 Move library-absorb operation to async task
And make it not mandatory in case of failure
2024-05-27 11:19:15 +02:00
Andrey Antukh
39119ac040 Reuse team deletion logic on orphan teams gc task 2024-05-27 11:17:00 +02:00
Andrey Antukh
761bbb7334 Add srepl helpers for delete/restore teams, projects, and files 2024-05-27 11:17:00 +02:00
Andrey Antukh
abff7d324d Improve auth-data xdomain cookie 2024-05-27 10:58:05 +02:00
Chan Young Park
6c34706160 🌐 Add translations for: Korean.
Currently translated at 16.2% (224 of 1379 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/ko/
2024-05-25 20:09:22 +02:00
Alejandro
c3c6879a2f Merge pull request #4616 from penpot/hiru-prepare-builder-for-figma-exporter
Prepare builder for figma exporter
2024-05-24 14:57:15 +02:00
Alejandro Alonso
b073c23ced Merge remote-tracking branch 'origin/staging' into develop 2024-05-24 13:16:53 +02:00
Alejandro Alonso
39613944bb Merge remote-tracking branch 'origin/staging' 2024-05-24 13:15:59 +02:00
Eva Marco
9194e257b6 🐛 Fix project name ellipsis 2024-05-24 13:15:09 +02:00
Andrés Moya
7bcb2b928d 🔧 Remove trace 2024-05-24 13:09:27 +02:00
Andrés Moya
3bf76e8d0f 🐛 Better handling of components v2 in file builder 2024-05-24 13:09:27 +02:00
Pablo Alba
260c0e0678 Add copying and duplicating component frontend tests 2024-05-24 12:58:18 +02:00
alonso.torres
519b2d7f04 🐛 Fix problem when initializing plugin 2024-05-24 12:22:09 +02:00
Belén Albeza
4b05ee35b8 Merge pull request #4607 from penpot/ladybenko-7845-migrate-storybook-compile
 Remove storybook dependency on Gulp
2024-05-24 09:36:38 +02:00
Alejandro
5ab4ed9a05 Merge pull request #4621 from penpot/niwinz-objects-gc-locking
 Reduce locking on objects-gc task
2024-05-24 09:04:11 +02:00
Chan Young Park
a217d2085a 🌐 Add translations for: Korean.
Currently translated at 15.7% (217 of 1379 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/ko/
2024-05-23 22:09:23 +02:00
Andrey Antukh
72facff282 🔥 Remove unnecessary code from test helpers 2024-05-23 16:45:48 +02:00
Andrey Antukh
f3346786ea 🔥 Remove unused object-update task 2024-05-23 16:36:43 +02:00
Andrey Antukh
d241f45253 🔥 Remove unnecessary async touch operation 2024-05-23 16:36:35 +02:00
Andrey Antukh
584a0fdba1 Reduce locking on objects-gc task
The main issue was the long running gc operation that
affects storage objects with deduplication. The long running
transacion ends locking some storage object rows which collaterally
made operations like import-binfile become blocked indefinitelly
because of the same rows (because of deduplication).

The solution used in this commit is split operations on small
chunks so we no longer use long running transactions that holds
too many locks. With this approach we will make a window to work
concurrently all operarate the distinct operations that requires
locks on the same rows.
2024-05-23 16:35:54 +02:00
Alejandro
b54b99becf Merge pull request #4623 from penpot/niwinz-bugfix-2
🐛 Fix incorrect password encoding on create-profile manage command
2024-05-23 16:21:15 +02:00
Andrey Antukh
b357cf505d 🐛 Fix incorrect password encoding on create-profile manage command 2024-05-23 16:13:30 +02:00
Alejandro
12c34c6d42 Merge pull request #4620 from penpot/niwinz-bugfix-1
🐛 Bugfixes
2024-05-23 15:48:51 +02:00
Andrey Antukh
632165d6dc Merge branch 'AbdelatifAitBara-fix-docker-compose' into staging 2024-05-23 15:40:11 +02:00
AbdelatifAitBara
4d463537dd 🐛 Fix docker-compose version
Fixes #4545
2024-05-23 15:39:34 +02:00
Belén Albeza
dd3c92c1f5 Remove storybook dependency on Gulp 2024-05-23 15:12:29 +02:00
Andrey Antukh
86b2ce4dab 🐛 Set proper default tenant on exporter 2024-05-23 14:42:52 +02:00
Andrey Antukh
29ef9f752a 🐛 Fix incorrect password encoding on create-profile manage command 2024-05-23 14:42:28 +02:00
alonso.torres
4c7a30a029 ⬆️ Update plugins runtime 2024-05-23 14:24:12 +02:00
alonso.torres
3e6d3a2306 Add finish event for plugins 2024-05-23 14:24:12 +02:00
alonso.torres
5af77af6da 🐛 Fix problem running plugins from menu 2024-05-23 14:24:12 +02:00
Alejandro
fbd81e091d Merge pull request #4612 from penpot/niwinz-fix-devenv
 Improve yarn setup on devenv
2024-05-23 14:00:12 +02:00
Andrey Antukh
d9e4ee67c3 📎 Enable frontend integration tests 2024-05-23 13:25:03 +02:00
Andrey Antukh
7e5068f38e ⬆️ Update draft-js dependency commit reference
Fixes yarn.lock file
2024-05-23 13:19:22 +02:00
Belén Albeza
f74330dffe Add more timeout for playwright expects on CI 2024-05-23 13:18:51 +02:00
Alejandro Alonso
1d3d3f9b74 Add playwright dependencies to devenv docker 2024-05-23 13:18:49 +02:00
Alejandro
b28432f7fd Merge pull request #4618 from penpot/niwinz-ci-enhancements
 Improve yarn setup on devenv
2024-05-23 13:00:50 +02:00
Andrey Antukh
7158c4fd43 Improve yarn setup on devenv
And update yarn version to 4.2.2
2024-05-23 12:21:07 +02:00
Alejandro
20a7d668f5 Merge pull request #4617 from penpot/niwinz-fix-ci
🐳 Fix CI
2024-05-23 11:50:07 +02:00
Andrey Antukh
2c30dde198 📎 Disable frontend integration tests 2024-05-23 11:38:16 +02:00
Andrey Antukh
7f8c600837 📎 Fix cljs linter issue 2024-05-23 11:37:46 +02:00
Andrey Antukh
96844f5bea 📎 Fix cljs fmt linter issue 2024-05-23 11:37:38 +02:00
Andrey Antukh
4cb0e97db4 Revert "⬆️ Update JVM and NODE deps on devenv Dockerfile"
This reverts commit 0a1b255da7.
2024-05-22 18:08:49 +02:00
alonso.torres
4f4ce174ae Changes to the manifest loading 2024-05-22 17:30:19 +02:00
alonso.torres
85ae3ff6f8 🐛 Fix problem with hot reload 2024-05-22 17:30:19 +02:00
alonso.torres
9fcb4216b6 Improved performance to update layout 2024-05-22 17:30:19 +02:00
Alejandro Alonso
47d7d24910 Add copying and duplicating component tests 2024-05-22 14:26:03 +02:00
Alejandro Alonso
ae6cb551cb Merge remote-tracking branch 'origin/staging' 2024-05-22 13:03:20 +02:00
Alejandro Alonso
eb168a6f9f Merge remote-tracking branch 'origin/staging' into develop 2024-05-22 13:02:44 +02:00
alonso.torres
4ad0cc2680 ⬆️ Update plugins runtime 2024-05-22 12:25:28 +02:00
Aitor Moreno
8a74f24977 Merge pull request #4600 from penpot/eva-bugfixing
Eva bugfixing
2024-05-22 11:38:03 +02:00
Aitor Moreno
0f181df767 Merge pull request #4604 from penpot/eva-fix-scrollbar-chrome
🐛  Fix scrollbar with on chrome after 121 release
2024-05-22 11:19:21 +02:00
alonso.torres
dcb6315ff6 🐛 Fix problem with minification 2024-05-21 19:53:09 +02:00
alonso.torres
3ca5b13e27 New apis for plugins 2024-05-21 15:24:28 +02:00
alonso.torres
d6de1fdbdf ♻️ Refactor plugins proxies internal data 2024-05-21 15:24:28 +02:00
Eva Marco
8d104de41c 🐛 Fix scrollbar with on chrome after 121 release 2024-05-21 13:43:54 +02:00
Alejandro
b59dae57ca Merge pull request #4601 from penpot/niwinz-fire-package-lock
🔥 Remove package-lock.json file from repo root
2024-05-21 13:15:59 +02:00
Andrey Antukh
0a1b255da7 ⬆️ Update JVM and NODE deps on devenv Dockerfile 2024-05-20 12:10:13 +02:00
Andrey Antukh
8d7b2008f5 🔥 Remove package-lock.json file from repo root 2024-05-20 12:07:20 +02:00
Eva Marco
c56c3f9588 🐛 Fix project name ellipsis 2024-05-20 11:28:52 +02:00
Eva Marco
bd9ef6d221 🐛 Change login notification to error 2024-05-20 09:40:25 +02:00
Eva Marco
76fc2b04f4 🐛 Add fallback color to code generation 2024-05-20 09:38:16 +02:00
Eva Marco
b48d568905 Merge pull request #4596 from penpot/ladybenko-fix-debug-css-template
Fix including Debug CSS in the index template
2024-05-20 09:34:23 +02:00
Amine Gdoura
50d1d19d25 🌐 Add translations for: Arabic.
Currently translated at 82.0% (1131 of 1379 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/ar/
2024-05-19 13:01:53 +02:00
Belén Albeza
e74ab949ba 🐛 Include debug css in local dev only 2024-05-17 16:48:03 +02:00
Belén Albeza
d30eca016e 💄 Reformat JS file 2024-05-17 16:47:15 +02:00
Eva Marco
4a3a5f701f 🐛 Fix demo account text color 2024-05-17 12:15:18 +02:00
Eva Marco
7461126d1a Merge pull request #4592 from penpot/ladybenko-set-e2e-workers-1
 Set default workers for front-end integration tests to 1
2024-05-17 11:05:10 +02:00
Belén Albeza
06ac5ae520 Set default workers for front-end integration tests to 1 2024-05-17 09:29:31 +02:00
Aitor Moreno
a3d4d62269 Merge pull request #4585 from penpot/alotor-plugins-api
Updates to Plugin API and menu
2024-05-16 15:26:28 +02:00
Alejandro Alonso
614af9edc4 Add swap as override component tests 2024-05-16 13:27:06 +02:00
Pablo Alba
d221241451 Components refactor: Add tests for remove swap slot on copy-paste 2024-05-16 13:25:25 +02:00
Andrés Moya
9c8a5484e1 🔥 Remove traces 2024-05-16 13:24:17 +02:00
Pablo Alba
385e8d837a Components refactor: Add tests for remove or keep swap slot 2024-05-16 13:23:02 +02:00
Alejandro Alonso
f27cdee5ca 🐛 Remove TODO on multiple nesting levels component tests 2024-05-16 13:22:42 +02:00
Alejandro Alonso
4b8322dc82 Refactor common tests 2024-05-16 13:22:42 +02:00
alonso.torres
0ddcfa05cf Update plugins runtime 2024-05-16 12:26:19 +02:00
alonso.torres
4c71a4367f Add plugins management dialog 2024-05-16 12:26:19 +02:00
alonso.torres
236ff06763 Expand api for plugins 2024-05-16 11:05:01 +02:00
Eva Marco
6e409cbd47 Merge pull request #4583 from penpot/ladybenko-7730-ws-flaky
Fix flakiness of workspace tests
2024-05-14 16:46:18 +02:00
Belén Albeza
d43458ee89 🐛 Fix mocking websockets when running multiple tests 2024-05-14 16:36:54 +02:00
Alejandro Alonso
39c8b2ea3c Add multiple nesting levels component tests 2024-05-14 13:48:34 +02:00
Alejandro Alonso
fcf14b5cab Add duplicate page component tests 2024-05-14 13:48:34 +02:00
Alejandro Alonso
3e4aaa7935 Add new composition functions for common tests 2024-05-14 13:48:34 +02:00
Belén Albeza
575873eba7 🐛 Fix workspace rect drawing test 2024-05-13 17:41:00 +02:00
Andrés Moya
677b28218e 🔧 Update dependencies for fmt:clj 2024-05-13 13:31:38 +02:00
Pablo Alba
cddc50036f Merge pull request #4580 from penpot/hiru-refactor-frontend-tests
Refactor frontend test helpers
2024-05-13 13:24:55 +02:00
Andrés Moya
da939cc0a6 ♻️ Refactor front end test to make use of common file helpers 2024-05-13 13:10:01 +02:00
Andrés Moya
c16ef39abf ♻️ Make test helpers globally usable 2024-05-13 13:10:01 +02:00
AzazelN28
d8c60aa770 Skip failing test 2024-05-13 12:19:12 +02:00
Andy Li
ee0492120a 🌐 Add translations for: Chinese (Traditional).
Currently translated at 47.2% (651 of 1379 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/zh_Hant/
2024-05-12 11:01:11 +02:00
Aitor Moreno
0419b2c405 Merge pull request #4565 from penpot/eva-dashboard-pom-basic
  Add basic dashboard POM and test
2024-05-10 14:35:43 +02:00
Eva Marco
d341cef406 Add basic dashboard pom and test 2024-05-10 12:53:26 +02:00
Alejandro
ea20f693cb Merge pull request #4562 from penpot/hiru-move-frontend-tests
Move more frontend tests
2024-05-10 11:04:31 +02:00
Alejandro
a94f1d6fe4 Merge pull request #4547 from penpot/alotor-fix-problem-svg-styles
🐛 Fix style scoping problem with imported SVG
2024-05-10 10:54:05 +02:00
Alejandro
db99e994c6 Merge pull request #4570 from Cenadros/hotfix/fix-media-import
🐛 Fix medias not being imported using lib-penpot
2024-05-10 10:33:21 +02:00
Andrés Moya
cb73ddc353 💄 Small refactor 2024-05-10 10:28:23 +02:00
Alejandro
c616e3c932 Merge pull request #4540 from penpot/azazeln28-fix-color-palette-sorting-by-hue-and-value
🐛  Color palette sorting
2024-05-10 10:26:42 +02:00
Alejandro Alonso
a3e750ed0a Tests for chained components changes propagation 2024-05-10 10:25:08 +02:00
Andrés Moya
cf4ef426d7 Add tests for component sync 2024-05-10 10:17:09 +02:00
Belén Albeza
702e451530 Merge pull request #4572 from penpot/superalex-integration-tests
 Frontend integration tests
2024-05-10 09:30:48 +02:00
Alejandro Alonso
6b76213128 Frontend integration tests 2024-05-10 06:50:33 +02:00
Eva Marco
99371234dc Merge pull request #4563 from penpot/ladybenko-workspace-draw-test
Refactor POMS + extra workspace tests
2024-05-09 16:19:46 +02:00
Andrés Moya
b6e633865e Add tests for component creation and modification 2024-05-09 14:49:10 +02:00
Belén Albeza
00430d63eb Add test for drawing a shape in the workspace 2024-05-09 13:45:06 +02:00
Belén Albeza
e28d56e670 Add WorkspacePage POM for playwright testing 2024-05-09 13:45:02 +02:00
Andrés Moya
8b4e52a2be 💄 Improve copy child selection and test robustness 2024-05-09 13:33:52 +02:00
Andrés Moya
caefaf6016 Add tests for reset components 2024-05-09 13:33:52 +02:00
Alejandro
dd62653d4b Merge pull request #4571 from penpot/palba-fix-tests
🐛 Fix tests for remove swap slots
2024-05-09 13:20:24 +02:00
Pablo Alba
8deb799c3d 🐛 Fix tests for remove swap slots 2024-05-09 13:11:50 +02:00
Pablo Alba
6f93db034f 🎉 Components refactor: Add tests for remove swap slot on duplicate 2024-05-09 11:20:19 +02:00
Pablo Alba
bfe9caba15 ♻️ Components refactor: move generators for duplicate 2024-05-09 11:20:19 +02:00
Alex Sánchez
40bc1fac73 🐛 Fix medias not being imported using lib-penpot 2024-05-09 10:36:49 +02:00
Belén Albeza
9fd9e0178e ♻️ Refactor LoginPage POM 2024-05-08 12:17:53 +02:00
Pablo Alba
d92faaa6c6 Merge pull request #4558 from penpot/hiru-enhance-tests-debug
🔧 Enhance debug trace helpers for common tests
2024-05-07 22:12:05 +02:00
Andrés Moya
ea6a9c87ec 🔧 Enhance debug trace helpers for common tests 2024-05-07 18:45:10 +02:00
Belén Albeza
127c47a35a Merge pull request #4557 from penpot/azazeln28-test-add-websocket-mock
 Add basic test with websocket mock
2024-05-07 16:25:51 +02:00
AzazelN28
0091ac0f5f ♻️ Refactor tests and pages 2024-05-07 16:18:42 +02:00
Andrés Moya
b4ea749388 🐛 Fix linter error 2024-05-07 16:00:32 +02:00
Andrés Moya
86e524638c 🔥 Do a small cleanup 2024-05-07 15:51:56 +02:00
Pablo Alba
e7b065ac6c Merge pull request #4552 from penpot/hiru-move-touched-test
 Move more touched tests to common
2024-05-07 13:00:25 +02:00
Andrés Moya
c937d49ce9 💄 Split helpers in separated files 2024-05-07 12:51:07 +02:00
Andrés Moya
97e34d6e28 💄 Unify comments 2024-05-07 12:51:07 +02:00
Andrés Moya
b68bc9a08c Move more touched tests to common 2024-05-07 12:51:07 +02:00
Alejandro Alonso
1de138466f Merge remote-tracking branch 'origin/staging' into develop 2024-05-07 12:47:40 +02:00
Alejandro Alonso
bbb64b8be9 Merge remote-tracking branch 'origin/staging' 2024-05-07 12:47:17 +02:00
AzazelN28
572c6f02e2 ♻️ Refactor MockWebSocket 2024-05-07 11:59:33 +02:00
Belén Albeza
3bae6e4661 Adapt mock and add workspace test with websocket mock 2024-05-07 11:59:33 +02:00
AzazelN28
30321e54f0 📎 Add WebSocket mock 2024-05-07 11:59:33 +02:00
Aitor Moreno
38e35fb5ae Merge pull request #4555 from penpot/eva-testing-login-pom
 Add login page as Page Object Model
2024-05-07 10:58:08 +02:00
Eva Marco
832c1db63b Add login page as Page Object Model 2024-05-07 10:28:17 +02:00
Pablo Alba
da437a0902 Merge pull request #4554 from penpot/hiru-create-logic-module
♻️ Move generate-xx methods to logic module
2024-05-06 18:48:44 +02:00
Andrés Moya
0b4fbc184d ♻️ Move generate-xx methods to logic module 2024-05-06 16:48:18 +02:00
Pablo Alba
7280dfd3f7 Tests for remove swap slot on move shapes to frame 2024-05-06 16:18:43 +02:00
Aitor Moreno
2c3ae851ea Merge pull request #4541 from penpot/superalex-delete-bottle-tutorial-and-walkthrough-from-onboarding-dashboard
 Delete Bottle tutorial and walkthrough from onboarding das…
2024-05-06 15:14:51 +02:00
Belén Albeza
e666127b57 Merge pull request #4500 from penpot/eva-login-tests-additions
 Add more login integration tests
2024-05-06 15:03:43 +02:00
Aitor Moreno
5436633104 Merge pull request #4536 from penpot/alotor-plugins-api
New plugins APIs
2024-05-06 12:17:49 +02:00
alonso.torres
ca7f17efd1 Add items to grid cells 2024-05-06 12:02:29 +02:00
alonso.torres
7117ea1f7e 🐛 Fix style scoping problem with imported SVG 2024-05-06 09:16:57 +02:00
Andy Li
f575650379 🌐 Add translations for: Chinese (Traditional).
Currently translated at 46.7% (644 of 1379 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/zh_Hant/
2024-05-05 07:07:10 +02:00
Stas Haas
5f560426fa 🌐 Add translations for: Russian.
Currently translated at 57.5% (794 of 1379 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/ru/
2024-05-03 15:07:10 +02:00
Louis Chance
402b6d4f34 🌐 Add translations for: French.
Currently translated at 100.0% (1379 of 1379 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/fr/
2024-05-03 15:07:08 +02:00
alonso.torres
fde0bcfd3e Add grid layout options to context 2024-05-03 13:44:31 +02:00
alonso.torres
9243ba937d Add to plugins clone and remove 2024-05-03 11:36:59 +02:00
alonso.torres
e30c21a71f Add relative positioning 2024-05-03 11:36:59 +02:00
alonso.torres
67d48435e7 Plugins create svg shapes 2024-05-03 11:36:59 +02:00
alonso.torres
21d38a058b Add to plugin api: upload media, group and ungroup 2024-05-03 11:36:59 +02:00
alonso.torres
75d8965365 Add method to append children 2024-05-03 11:36:59 +02:00
alonso.torres
4a74862bf5 Add viewport information to the plugin 2024-05-03 11:36:59 +02:00
TheScientistPT
43dd4ce457 🌐 Add translations for: Portuguese (Portugal).
Currently translated at 98.5% (1359 of 1379 strings)

Co-authored-by: TheScientistPT <joao.ed.reis.gomes@gmail.com>
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/pt_PT/
Translation: Penpot/frontend
2024-05-01 10:07:43 +02:00
Yaron Shahrabani
cd03794a09 🌐 Add translations for: Hebrew.
Currently translated at 100.0% (1379 of 1379 strings)

Co-authored-by: Yaron Shahrabani <sh.yaron@gmail.com>
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/he/
Translation: Penpot/frontend
2024-05-01 10:07:42 +02:00
Stas Haas
a749519d8e 🌐 Add translations for: German.
Currently translated at 100.0% (1379 of 1379 strings)

Co-authored-by: Stas Haas <stas@girafic.de>
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/de/
Translation: Penpot/frontend
2024-05-01 10:07:41 +02:00
Linerly
71687593fd 🌐 Add translations for: Indonesian.
Currently translated at 100.0% (1379 of 1379 strings)

Co-authored-by: Linerly <linerly@proton.me>
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/id/
Translation: Penpot/frontend
2024-05-01 10:07:39 +02:00
Geek Squirrel
a7eb70a8e0 🌐 Add translations for: Chinese (Simplified).
Currently translated at 99.4% (1371 of 1379 strings)

🌐 Add translations for: Chinese (Simplified).

Currently translated at 95.5% (1317 of 1379 strings)

Co-authored-by: Geek Squirrel <geeksquirrel@qq.com>
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/zh_Hans/
Translation: Penpot/frontend
2024-05-01 10:07:38 +02:00
Pablo Alba
5e396010b3 Merge pull request #4535 from penpot/hiru-move-front-tests
Move frontend tests to common
2024-04-30 19:31:50 +02:00
Pablo Alba
de6d8ccbf9 Small fix on components touched test 2024-04-30 19:23:58 +02:00
Alejandro Alonso
0fc7d8529e Delete Bottle tutorial and walkthrough from onboarding dashboard 2024-04-30 16:49:23 +02:00
Alejandro Alonso
bca8180aeb 🐛 Fix duplicate component 2024-04-30 16:46:36 +02:00
Andrés Moya
77d4901db1 Add more tests for touched 2024-04-30 14:18:55 +02:00
Andrés Moya
a40afd5b63 Add test for touched shapes 2024-04-30 13:47:40 +02:00
Andrés Moya
5611fcfc2c 🔧 Add generator function for update-shapes 2024-04-30 13:47:40 +02:00
Pablo Alba
f354942487 ♻️ Components refactor: generator for relocate shapes (and tests) 2024-04-30 13:37:32 +02:00
Pablo Alba
78d0611632 Merge pull request #4538 from penpot/superalex-swap-and-reset-generate-tests
 Swap and reset generate changes tests
2024-04-30 13:17:15 +02:00
Alejandro Alonso
f84cd933a8 Swap and reset generate changes tests 2024-04-30 12:49:43 +02:00
Yamila Moreno
d956f7c72c Update README.md
update penpot fest information
2024-04-30 12:21:28 +02:00
AzazelN28
a8fae53564 🐛 color palette sorting 2024-04-30 10:03:53 +02:00
Aitor Moreno
b2e40155b0 Merge pull request #4519 from penpot/ladybenko-use-custom-server
 Swap http-server for a custom server with express (front-end integration tests)
2024-04-29 18:12:00 +02:00
Alejandro
013dbf1f76 Merge pull request #4499 from penpot/hiru-test-helpers
 Add helpers to build files for testing
2024-04-26 13:29:52 +02:00
Alejandro Alonso
cf62b083fe Merge remote-tracking branch 'origin/staging' into develop 2024-04-26 12:50:43 +02:00
Alejandro
23bd57e9bb Merge pull request #4531 from penpot/alotor-fix-font-bug
🐛 Fix problem with exporter texts
2024-04-26 12:49:45 +02:00
Andrés Moya
40e43fd501 ♻️ Reorganize tests by level 2024-04-26 12:44:49 +02:00
Andrés Moya
ff4e27a1d5 Add composition helpers 2024-04-26 12:44:49 +02:00
Alejandro
11f2d7e711 Merge pull request #4530 from penpot/palba-fix-wrong-permissions
🐛 Fix inspect permission on shared prototype for owners
2024-04-26 12:43:34 +02:00
alonso.torres
3a71068a48 🐛 Add warning when font cannot be found 2024-04-26 12:16:05 +02:00
alonso.torres
bebdc78ce6 🐛 Fix problem with exporter texts 2024-04-26 12:15:37 +02:00
Pablo Alba
22939aa689 🐛 Fix inspect permission on shared prototype for owners 2024-04-26 11:55:56 +02:00
Andrés Moya
dde89e60dd Add new helper functions for common tests 2024-04-26 11:45:37 +02:00
Andrés Moya
1026f5b972 🔧 Change common tests runner to kaocha 2024-04-26 11:42:41 +02:00
Pablo Alba
6901acb37e 🐛 Fix ungrouping detach components 2024-04-26 11:41:43 +02:00
Pablo Alba
e0fe7181f1 Merge pull request #4522 from penpot/superalex-fix-update-temp-file-audit-log-stored-dat
🐛 Fix update-temp-file audit_log stored data
2024-04-26 11:02:10 +02:00
Alejandro
d1a8427563 Merge pull request #4528 from penpot/translations-2024-04-26-12
:sparkes: Update translations
2024-04-26 09:07:27 +02:00
Hosted Weblate
ee6245d2d1 Update translation files
Updated by "Cleanup translation files" hook in Weblate.

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/
2024-04-26 09:06:15 +02:00
Alejandro
e7247817fb Merge pull request #4527 from penpot/translations-2024-04-26-11
Translations 2024 04 26 11
2024-04-26 08:58:29 +02:00
Alejandro Alonso
43fedb5fd4 Merge remote-tracking branch 'weblate/develop' into translations-2024-04-26-11 2024-04-26 08:57:20 +02:00
Alejandro
708c44d3f1 Merge pull request #4526 from penpot/translations-2024-04-26-9
 Update translations
2024-04-26 08:53:40 +02:00
Alejandro Alonso
1361917569 🌐 Add translations for: Spanish.
Currently translated at 99.8% (1377 of 1379 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/es/
2024-04-26 08:51:54 +02:00
Stephan Paternotte
5394fce632 🌐 Add translations for: Dutch.
Currently translated at 100.0% (1379 of 1379 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/nl/
2024-04-26 08:51:54 +02:00
Edgars Andersons
4b05551ecc 🌐 Add translations for: Latvian.
Currently translated at 100.0% (1379 of 1379 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/lv/
2024-04-26 08:51:54 +02:00
Yaron Shahrabani
3cb6c501d3 🌐 Add translations for: Hebrew.
Currently translated at 98.9% (1364 of 1379 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/he/
2024-04-26 08:51:54 +02:00
Stas Haas
c754e606ac 🌐 Add translations for: German.
Currently translated at 99.7% (1376 of 1379 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/de/
2024-04-26 08:51:54 +02:00
Oğuz Ersen
258ead34f0 🌐 Add translations for: Turkish.
Currently translated at 100.0% (1379 of 1379 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/tr/
2024-04-26 08:51:54 +02:00
Anonymous
871a08aa75 🌐 Add translations for: Yoruba.
Currently translated at 88.5% (1221 of 1379 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/yo/
2024-04-26 08:51:53 +02:00
Anonymous
476099c06a 🌐 Add translations for: Chinese (Traditional).
Currently translated at 44.5% (615 of 1379 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/zh_Hant/
2024-04-26 08:51:53 +02:00
Yaron Shahrabani
b74ae49f38 🌐 Add translations for: Hebrew.
Currently translated at 97.7% (1348 of 1379 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/he/
2024-04-26 08:51:53 +02:00
Anonymous
51eabd2a23 🌐 Add translations for: Chinese (Simplified).
Currently translated at 95.4% (1316 of 1379 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/zh_Hans/
2024-04-26 08:51:53 +02:00
Oğuz Ersen
522909c66d 🌐 Add translations for: Turkish.
Currently translated at 97.8% (1350 of 1379 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/tr/
2024-04-26 08:51:53 +02:00
Anonymous
d2204ad48c 🌐 Add translations for: Turkish.
Currently translated at 97.8% (1350 of 1379 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/tr/
2024-04-26 08:51:53 +02:00
Anonymous
158753073c 🌐 Add translations for: Igbo.
Currently translated at 40.0% (546 of 1362 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/ig/
2024-04-26 08:51:53 +02:00
Anonymous
46705d9ebc 🌐 Add translations for: Malay.
Currently translated at 52.0% (709 of 1362 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/ms/
2024-04-26 08:51:53 +02:00
Anonymous
10c64330eb 🌐 Add translations for: Hausa.
Currently translated at 96.1% (1309 of 1362 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/ha/
2024-04-26 08:51:53 +02:00
Anonymous
16a5218592 🌐 Add translations for: Dutch.
Currently translated at 100.0% (1362 of 1362 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/nl/
2024-04-26 08:51:53 +02:00
Anonymous
6cf0605745 🌐 Add translations for: Latvian.
Currently translated at 100.0% (1362 of 1362 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/lv/
2024-04-26 08:51:53 +02:00
Anonymous
155346fa09 🌐 Add translations for: Portuguese (Portugal).
Currently translated at 100.0% (1362 of 1362 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/pt_PT/
2024-04-26 08:51:53 +02:00
Anonymous
3cf385e209 🌐 Add translations for: Czech.
Currently translated at 98.6% (1344 of 1362 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/cs/
2024-04-26 08:51:53 +02:00
Anonymous
16873891cb 🌐 Add translations for: Basque.
Currently translated at 87.5% (1192 of 1362 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/eu/
2024-04-26 08:51:53 +02:00
Anonymous
861348f97b 🌐 Add translations for: Polish.
Currently translated at 85.3% (1162 of 1362 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/pl/
2024-04-26 08:51:53 +02:00
Anonymous
f60c405167 🌐 Add translations for: Persian.
Currently translated at 50.0% (681 of 1362 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/fa/
2024-04-26 08:51:53 +02:00
Anonymous
6a2bdeb3cb 🌐 Add translations for: Hebrew.
Currently translated at 100.0% (1362 of 1362 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/he/
2024-04-26 08:51:53 +02:00
Anonymous
5434ed146e 🌐 Add translations for: Indonesian.
Currently translated at 100.0% (1362 of 1362 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/id/
2024-04-26 08:51:53 +02:00
Anonymous
0ab9300107 🌐 Add translations for: Arabic.
Currently translated at 83.1% (1132 of 1362 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/ar/
2024-04-26 08:51:53 +02:00
Anonymous
c40e3815df 🌐 Add translations for: Romanian.
Currently translated at 96.1% (1310 of 1362 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/ro/
2024-04-26 08:51:53 +02:00
Anonymous
a3cec26994 🌐 Add translations for: German.
Currently translated at 100.0% (1362 of 1362 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/de/
2024-04-26 08:51:53 +02:00
Anonymous
5523914605 🌐 Add translations for: Portuguese (Brazil).
Currently translated at 85.2% (1161 of 1362 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/pt_BR/
2024-04-26 08:51:53 +02:00
Anonymous
7a849dd5c4 🌐 Add translations for: French.
Currently translated at 96.4% (1313 of 1362 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/fr/
2024-04-26 08:51:53 +02:00
Anonymous
6d3596ba14 🌐 Add translations for: Spanish.
Currently translated at 99.3% (1353 of 1362 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/es/
2024-04-26 08:51:53 +02:00
Hosted Weblate
1f4266ffe4 Update translation files
Updated by "Cleanup translation files" hook in Weblate.

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/
2024-04-26 08:51:53 +02:00
TheScientistPT
0fd31c253a 🌐 Add translations for: Portuguese (Portugal).
Currently translated at 100.0% (1362 of 1362 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/pt_PT/
2024-04-26 08:51:52 +02:00
Edgars Andersons
aae02bfedb 🌐 Add translations for: Latvian.
Currently translated at 100.0% (1362 of 1362 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/lv/
2024-04-26 08:51:52 +02:00
Linerly
f9514f62a7 🌐 Add translations for: Indonesian.
Currently translated at 100.0% (1362 of 1362 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/id/
2024-04-26 08:51:52 +02:00
Stas Haas
04359701a3 🌐 Add translations for: German.
Currently translated at 100.0% (1362 of 1362 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/de/
2024-04-26 08:51:52 +02:00
Edgars Andersons
704103618b 🌐 Add translations for: Latvian.
Currently translated at 100.0% (1362 of 1362 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/lv/
2024-04-26 08:51:52 +02:00
Louis Chance
f3a0f818aa 🌐 Add translations for: French.
Currently translated at 96.4% (1313 of 1362 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/fr/
2024-04-26 08:51:52 +02:00
Yaron Shahrabani
17b01b97cf 🌐 Add translations for: Hebrew.
Currently translated at 100.0% (1362 of 1362 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/he/
2024-04-26 08:51:52 +02:00
Stas Haas
bb0427d613 🌐 Add translations for: German.
Currently translated at 100.0% (1362 of 1362 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/de/
2024-04-26 08:51:52 +02:00
Alejandro Alonso
a0aec8023a 🌐 Add translations for: Yoruba.
Currently translated at 90.6% (1234 of 1362 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/yo/
2024-04-26 08:51:52 +02:00
Alejandro Alonso
2204799429 🌐 Add translations for: Igbo.
Currently translated at 40.0% (546 of 1362 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/ig/
2024-04-26 08:51:52 +02:00
Alejandro Alonso
f970397b36 🌐 Added translation for: Yoruba. 2024-04-26 08:51:52 +02:00
Alejandro Alonso
e15667bc39 🌐 Added translation for: Igbo. 2024-04-26 08:51:52 +02:00
Alejandro Alonso
9e9771fa1e 🌐 Deleted translation: Yoruba. 2024-04-26 08:51:52 +02:00
Alejandro Alonso
b3d46a59e3 🌐 Add translations for: Yoruba.
Currently translated at 1.5% (21 of 1362 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/yo/
2024-04-26 08:51:52 +02:00
Alejandro Alonso
d2a85dcd37 🌐 Added translation for: Yoruba. 2024-04-26 08:51:52 +02:00
Stephan Paternotte
316242ac67 🌐 Add translations for: Dutch.
Currently translated at 100.0% (1362 of 1362 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/nl/
2024-04-26 08:51:52 +02:00
TheScientistPT
8adcb82c45 🌐 Add translations for: Portuguese (Portugal).
Currently translated at 100.0% (1362 of 1362 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/pt_PT/
2024-04-26 08:51:52 +02:00
Stas Haas
062c086eca 🌐 Add translations for: German.
Currently translated at 100.0% (1362 of 1362 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/de/
2024-04-26 08:51:52 +02:00
Revenant
dc53c60db6 🌐 Add translations for: Malay.
Currently translated at 52.0% (709 of 1362 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/ms/
2024-04-26 08:51:52 +02:00
Oğuz Ersen
2166435a52 🌐 Add translations for: Turkish.
Currently translated at 100.0% (1362 of 1362 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/tr/
2024-04-26 08:51:52 +02:00
Alejandro
4df2d7a49b Merge pull request #4525 from penpot/translations-2024-04-26-7
 Update translations
2024-04-26 08:47:11 +02:00
Oğuz Ersen
15debe65fd Update translations 2024-04-26 08:46:41 +02:00
Alejandro Alonso
007bd86f09 🌐 Add translations for: Spanish.
Currently translated at 99.8% (1377 of 1379 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/es/
2024-04-26 06:53:02 +02:00
Alejandro Alonso
a65282c01b 🐛 Fix update-temp-file audit_log stored data 2024-04-26 06:30:00 +02:00
Alejandro
625bfa7166 Merge pull request #4520 from penpot/alotor-fix-exporter-problem
🐛 Fix problem with exporter texts
2024-04-25 16:30:32 +02:00
alonso.torres
a8363f0c02 🐛 Fix problem with exporter texts 2024-04-25 15:35:53 +02:00
Stephan Paternotte
8abc2261a6 🌐 Add translations for: Dutch.
Currently translated at 100.0% (1379 of 1379 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/nl/
2024-04-25 15:07:21 +02:00
Edgars Andersons
e4178a66d6 🌐 Add translations for: Latvian.
Currently translated at 100.0% (1379 of 1379 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/lv/
2024-04-25 15:07:20 +02:00
Yaron Shahrabani
ca7bd20c33 🌐 Add translations for: Hebrew.
Currently translated at 98.9% (1364 of 1379 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/he/
2024-04-25 15:07:19 +02:00
Stas Haas
77f61191d1 🌐 Add translations for: German.
Currently translated at 99.7% (1376 of 1379 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/de/
2024-04-25 15:07:19 +02:00
Oğuz Ersen
4896d39261 🌐 Add translations for: Turkish.
Currently translated at 100.0% (1379 of 1379 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/tr/
2024-04-25 15:07:18 +02:00
Pablo Alba
a7bfa7c7c8 ♻️ Components refactor: generator for sync-file 2024-04-25 14:22:37 +02:00
Alejandro Alonso
c73eb77125 ♻️ Components refactor: generator for reset component 2024-04-25 14:22:37 +02:00
Alejandro Alonso
f3220fa985 ♻️ Components refactor: generator for sync head 2024-04-25 14:22:37 +02:00
Pablo Alba
37e68249aa ♻️ Components refactor: remove it usage on libraries_helpers 2024-04-25 14:22:37 +02:00
Alejandro Alonso
05f4459fb7 ♻️ Components refactor: generator for generate component for swap 2024-04-25 14:22:37 +02:00
Alejandro Alonso
c001710676 ♻️ Components refactor: generator for delete shapes 2024-04-25 14:22:37 +02:00
Pablo Alba
0ed582ebc5 ♻️ Components refactor: generator for detach-component 2024-04-25 14:22:37 +02:00
Pablo Alba
7d44eef4ab ♻️ Components refactor: generator for restore-component 2024-04-25 14:22:37 +02:00
Pablo Alba
f91d60eeb6 ♻️ Components refactor: generator for rename-component 2024-04-25 14:22:37 +02:00
Pablo Alba
02c455dcba ♻️ Components refactor: generator for duplicate component 2024-04-25 14:22:37 +02:00
Belén Albeza
306a8edbec Swap http-server for a custom server with express (front-end integration tests) 2024-04-25 13:40:14 +02:00
AzazelN28
47804429c0 Merge branch 'staging' into develop 2024-04-25 11:32:28 +02:00
Alejandro Alonso
5b35176584 Merge remote-tracking branch 'origin/staging' 2024-04-25 10:29:04 +02:00
Eva Marco
106fe05657 Add more login integration tests 2024-04-25 09:56:10 +02:00
Anonymous
e2f6b02075 🌐 Add translations for: Yoruba.
Currently translated at 88.5% (1221 of 1379 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/yo/
2024-04-24 15:04:10 +02:00
Anonymous
9a54785291 🌐 Add translations for: Chinese (Traditional).
Currently translated at 44.5% (615 of 1379 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/zh_Hant/
2024-04-24 15:04:10 +02:00
Yaron Shahrabani
9ba7bb7e17 🌐 Add translations for: Hebrew.
Currently translated at 97.7% (1348 of 1379 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/he/
2024-04-24 15:04:09 +02:00
Anonymous
7d0bae6619 🌐 Add translations for: Chinese (Simplified).
Currently translated at 95.4% (1316 of 1379 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/zh_Hans/
2024-04-24 15:04:09 +02:00
Oğuz Ersen
ec9e32241d 🌐 Add translations for: Turkish.
Currently translated at 97.8% (1350 of 1379 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/tr/
2024-04-24 15:04:09 +02:00
Anonymous
a55bf34155 🌐 Add translations for: Turkish.
Currently translated at 97.8% (1350 of 1379 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/tr/
2024-04-24 15:04:09 +02:00
Alejandro
e808818f02 Merge pull request #4507 from penpot/translations-8
 Update translations
2024-04-24 15:00:19 +02:00
Oğuz Ersen
d3f8abb9aa Update translations 2024-04-24 14:57:12 +02:00
Anonymous
aa56c293ca 🌐 Add translations for: Igbo.
Currently translated at 40.0% (546 of 1362 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/ig/
2024-04-24 14:55:21 +02:00
Anonymous
8cfc669d9d 🌐 Add translations for: Malay.
Currently translated at 52.0% (709 of 1362 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/ms/
2024-04-24 14:55:20 +02:00
Anonymous
3068721fc3 🌐 Add translations for: Hausa.
Currently translated at 96.1% (1309 of 1362 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/ha/
2024-04-24 14:55:19 +02:00
Anonymous
cd06bb13ba 🌐 Add translations for: Dutch.
Currently translated at 100.0% (1362 of 1362 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/nl/
2024-04-24 14:55:18 +02:00
Anonymous
11cca08ec1 🌐 Add translations for: Latvian.
Currently translated at 100.0% (1362 of 1362 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/lv/
2024-04-24 14:55:17 +02:00
Anonymous
8f9ba827d8 🌐 Add translations for: Portuguese (Portugal).
Currently translated at 100.0% (1362 of 1362 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/pt_PT/
2024-04-24 14:55:16 +02:00
Anonymous
ddd0e10c84 🌐 Add translations for: Czech.
Currently translated at 98.6% (1344 of 1362 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/cs/
2024-04-24 14:55:15 +02:00
Anonymous
e97162bdae 🌐 Add translations for: Basque.
Currently translated at 87.5% (1192 of 1362 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/eu/
2024-04-24 14:55:15 +02:00
Anonymous
b87b1120ca 🌐 Add translations for: Polish.
Currently translated at 85.3% (1162 of 1362 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/pl/
2024-04-24 14:55:14 +02:00
Anonymous
4b5d75bef0 🌐 Add translations for: Persian.
Currently translated at 50.0% (681 of 1362 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/fa/
2024-04-24 14:55:13 +02:00
Anonymous
330dddbc31 🌐 Add translations for: Hebrew.
Currently translated at 100.0% (1362 of 1362 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/he/
2024-04-24 14:55:13 +02:00
Anonymous
609ffae580 🌐 Add translations for: Indonesian.
Currently translated at 100.0% (1362 of 1362 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/id/
2024-04-24 14:55:12 +02:00
Anonymous
eef05c2352 🌐 Add translations for: Arabic.
Currently translated at 83.1% (1132 of 1362 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/ar/
2024-04-24 14:55:11 +02:00
Anonymous
19639fed2d 🌐 Add translations for: Romanian.
Currently translated at 96.1% (1310 of 1362 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/ro/
2024-04-24 14:55:10 +02:00
Anonymous
a7785f3a47 🌐 Add translations for: German.
Currently translated at 100.0% (1362 of 1362 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/de/
2024-04-24 14:55:09 +02:00
Anonymous
b1e645abe6 🌐 Add translations for: Portuguese (Brazil).
Currently translated at 85.2% (1161 of 1362 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/pt_BR/
2024-04-24 14:55:09 +02:00
Anonymous
bb5f5eaba2 🌐 Add translations for: French.
Currently translated at 96.4% (1313 of 1362 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/fr/
2024-04-24 14:55:08 +02:00
Anonymous
990714c1da 🌐 Add translations for: Spanish.
Currently translated at 99.3% (1353 of 1362 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/es/
2024-04-24 14:55:07 +02:00
Hosted Weblate
68d59051fc Update translation files
Updated by "Cleanup translation files" hook in Weblate.

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/
2024-04-24 14:52:04 +02:00
TheScientistPT
30b0a2eddb 🌐 Add translations for: Portuguese (Portugal).
Currently translated at 100.0% (1362 of 1362 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/pt_PT/
2024-04-24 14:52:02 +02:00
Edgars Andersons
084378556b 🌐 Add translations for: Latvian.
Currently translated at 100.0% (1362 of 1362 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/lv/
2024-04-24 14:52:02 +02:00
Linerly
84b0905096 🌐 Add translations for: Indonesian.
Currently translated at 100.0% (1362 of 1362 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/id/
2024-04-24 14:52:02 +02:00
Stas Haas
6e03267697 🌐 Add translations for: German.
Currently translated at 100.0% (1362 of 1362 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/de/
2024-04-24 14:52:02 +02:00
Edgars Andersons
11bfc45c0b 🌐 Add translations for: Latvian.
Currently translated at 100.0% (1362 of 1362 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/lv/
2024-04-24 14:52:02 +02:00
Louis Chance
8b17da4235 🌐 Add translations for: French.
Currently translated at 96.4% (1313 of 1362 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/fr/
2024-04-24 14:52:02 +02:00
Yaron Shahrabani
f410783283 🌐 Add translations for: Hebrew.
Currently translated at 100.0% (1362 of 1362 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/he/
2024-04-24 14:52:02 +02:00
Stas Haas
b4e46347d4 🌐 Add translations for: German.
Currently translated at 100.0% (1362 of 1362 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/de/
2024-04-24 14:52:02 +02:00
Alejandro Alonso
a678eb7295 🌐 Add translations for: Yoruba.
Currently translated at 90.6% (1234 of 1362 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/yo/
2024-04-24 14:52:02 +02:00
Alejandro Alonso
f5d7dc7c5c 🌐 Add translations for: Igbo.
Currently translated at 40.0% (546 of 1362 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/ig/
2024-04-24 14:52:02 +02:00
Alejandro Alonso
5d899df456 🌐 Added translation for: Yoruba. 2024-04-24 14:52:02 +02:00
Alejandro Alonso
4e6dd09753 🌐 Added translation for: Igbo. 2024-04-24 14:52:02 +02:00
Alejandro Alonso
0eb35f352a 🌐 Deleted translation: Yoruba. 2024-04-24 14:52:02 +02:00
Alejandro Alonso
80b635af67 🌐 Add translations for: Yoruba.
Currently translated at 1.5% (21 of 1362 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/yo/
2024-04-24 14:52:02 +02:00
Alejandro Alonso
d5827562a3 🌐 Added translation for: Yoruba. 2024-04-24 14:52:02 +02:00
Stephan Paternotte
99417bd124 🌐 Add translations for: Dutch.
Currently translated at 100.0% (1362 of 1362 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/nl/
2024-04-24 14:52:02 +02:00
TheScientistPT
f3b68725d3 🌐 Add translations for: Portuguese (Portugal).
Currently translated at 100.0% (1362 of 1362 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/pt_PT/
2024-04-24 14:52:02 +02:00
Stas Haas
9369cf2d94 🌐 Add translations for: German.
Currently translated at 100.0% (1362 of 1362 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/de/
2024-04-24 14:52:02 +02:00
Revenant
b4853fca7a 🌐 Add translations for: Malay.
Currently translated at 52.0% (709 of 1362 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/ms/
2024-04-24 14:52:01 +02:00
Oğuz Ersen
727836af76 🌐 Add translations for: Turkish.
Currently translated at 100.0% (1362 of 1362 strings)

Translation: Penpot/frontend
Translate-URL: https://hosted.weblate.org/projects/penpot/frontend/tr/
2024-04-24 14:52:01 +02:00
Alejandro Alonso
0cc92eccfa Revert " Update translations"
This reverts commit 268a26b6a4.
2024-04-24 14:50:17 +02:00
Alejandro
2c6201f42a Merge pull request #4505 from penpot/superlex-update-translations-4
  Update translations
2024-04-24 14:13:26 +02:00
Aitor Moreno
857429290d Merge pull request #4501 from penpot/superalex-add-exception-audit-log-event
 Add exception page audit log event
2024-04-24 14:07:53 +02:00
Oğuz Ersen
268a26b6a4 Update translations 2024-04-24 14:06:29 +02:00
Alejandro Alonso
0be97e1c44 🐛 Fix validate translations script 2024-04-24 14:06:22 +02:00
Alejandro Alonso
3c842d2b81 Add exception page audit log event 2024-04-24 13:17:57 +02:00
alonso.torres
6fbdc4ff07 🐛 Fix problem activating feature 2024-04-24 10:25:47 +02:00
Alejandro
38fd385d5d Merge pull request #4467 from penpot/azazeln28-fix-color-palette-sorting
🐛 Fix color palette sorting
2024-04-24 08:22:33 +02:00
Aitor Moreno
3eabab7fc7 Merge pull request #4489 from penpot/alotor-plugins-create-api
 Add write apis to the plugins
2024-04-23 13:38:28 +02:00
Alejandro
9bf5b1a8cd Merge pull request #4491 from jordisala1991/hotfix/features-file-builder
🐛 Fix default features for files exported with penpot lib
2024-04-23 12:39:17 +02:00
Eva Marco
7c80c605d1 🐛 Fix background color on scrollbar for firefox 2024-04-23 11:25:18 +02:00
Jordi Sala Morales
0cb2e6d07d 🐛 Fix default features for files exported with penpot lib
Avoid having false as features, since it should be an array.
2024-04-23 07:40:16 +00:00
alonso.torres
00de89197e Add write apis to the plugins 2024-04-22 17:08:18 +02:00
Alejandro
d907812513 Merge pull request #4481 from jordisala1991/hotfix/page-options
🐛 Apply parse-data for addPage options
2024-04-22 14:53:53 +02:00
Alejandro
d8bf48e49e Merge pull request #4486 from penpot/azazeln28-add-provider-to-validate-uri
📎 Add provider to validate uri
2024-04-22 13:43:26 +02:00
Jordi Sala Morales
b667f1bb2c 🐛 Fix adding pages with customized options 2024-04-22 11:23:47 +00:00
Alejandro
8e9fa66e2f Merge pull request #4482 from penpot/palba-fix-remove-swap-slot
Fixes on swap slots
2024-04-22 13:20:28 +02:00
AzazelN28
17fb5283cc 📎 Add provider to validate uri 2024-04-22 13:13:42 +02:00
Alejandro
03c9f6b1e1 Merge pull request #4487 from penpot/superalex-fix-libraries-templates-links
🐛 Fix librares and templates links
2024-04-22 13:13:06 +02:00
Alejandro Alonso
908229b7a8 🐛 Fix librares and templates links 2024-04-22 13:04:48 +02:00
Alejandro
c85f76300a Merge pull request #4477 from penpot/comp-refactor-lib-helpers
♻️ Move and merge libraries_helpers
2024-04-22 12:58:11 +02:00
Pablo Alba
2a752e3625 🐛 swap slot is not copied on copy-paste of a main 2024-04-22 11:32:31 +02:00
Pablo Alba
c6fabc349e 🐛 Fix swap-slot is removed on copy-paste of a chained copy 2024-04-22 11:21:34 +02:00
Eva Marco
2fd55e3289 Merge pull request #4471 from penpot/ladybenko-7534-intercepting-login-seq
Integration test example: User login
2024-04-22 09:07:37 +02:00
Alejandro Alonso
3ea3923751 Merge remote-tracking branch 'origin/staging' 2024-04-22 09:07:06 +02:00
Belén Albeza
c33d4ff3e2 Add user login front-end integration test 2024-04-19 17:55:19 +02:00
Pablo Alba
a8738b44a1 ♻️ Merge libraries_common_helpers into libraries_helpers 2024-04-19 16:00:38 +02:00
Pablo Alba
2e18ce9323 ♻️ Move libraries_helpers to common 2024-04-19 15:37:29 +02:00
Pablo Alba
e1cd6d04d9 ♻️ Move common libraries_helpers to libraries_common_helpers 2024-04-19 14:02:27 +02:00
alonso.torres
362d4ea47f Command to activate feature plugin 2024-04-19 12:09:20 +02:00
AzazelN28
293ab3c80e 🐛 Fix color palette sorting 2024-04-19 10:31:54 +02:00
Andrey Antukh
716211524b Merge remote-tracking branch 'origin/staging' into develop 2024-04-19 09:37:37 +02:00
Alejandro
89fa8ce66e Merge pull request #4466 from penpot/azazeln28-fix-seo-issues
📎 Fix SEO issues
2024-04-19 09:27:27 +02:00
alonso.torres
d530815860 Upload plugins-runtime binary 2024-04-19 01:29:13 +02:00
alonso.torres
0ffd82299f Refactor to the context api 2024-04-19 01:29:13 +02:00
alonso.torres
7b508f2803 Create feature for plugins 2024-04-19 01:29:13 +02:00
alonso.torres
d7324b2e98 Support development and production plugin runtime 2024-04-19 01:29:13 +02:00
alonso.torres
97c3abfd60 Add nginx configuration for mjs files 2024-04-19 01:29:13 +02:00
alonso.torres
432e894344 Experiment for data definition 2024-04-19 01:29:13 +02:00
alonso.torres
127b481c38 Refactor of the plugins context 2024-04-19 01:29:13 +02:00
Juanfran
5a34c25926 🐛 Fix events inside webcomponent 2024-04-19 01:29:13 +02:00
Andrey Antukh
3f473ca765 Plugins proof of concept 2024-04-19 01:29:13 +02:00
AzazelN28
3bf5648b5b 📎 Fix SEO issues 2024-04-18 11:39:48 +02:00
Andrey Antukh
fd92437f7d Show error notificaton on oidc error redirect 2024-04-18 09:52:24 +02:00
Andrey Antukh
81b52d7170 Disable oidc registration when registration flag is disabled 2024-04-18 09:52:24 +02:00
Andrey Antukh
a969550aa4 Trust oidc providers which provides email_verified claim 2024-04-18 09:52:24 +02:00
Andrey Antukh
7e20cf10c5 ⬆️ Update dependencies 2024-04-18 09:52:24 +02:00
Andrey Antukh
90022041e6 Improve error handling on ldap frontend code 2024-04-18 09:52:24 +02:00
Andrey Antukh
ce790d83fd Improve internal registration flow 2024-04-18 09:52:24 +02:00
Andrey Antukh
606aeeb38f Allow attach context to audit entry from metadata 2024-04-18 09:52:24 +02:00
Andrey Antukh
ef632bcae7 Trigger email verification on OIDC register process
This will happen only if:
- the oidc provider properly reports that user has a non-verified email
- the oidc does not provides any way to know the email verification
  status
2024-04-18 09:52:24 +02:00
alonso.torres
57346ab685 📚 Update changelog to reflect breaking change 2024-04-17 19:57:02 +02:00
Andrey Antukh
b9ed0e1146 Merge remote-tracking branch 'origin/staging' into develop 2024-04-17 19:32:39 +02:00
Alejandro
8bd9c0d031 Merge pull request #4444 from penpot/palba-bugfixing-008
🐛 Bugfixing
2024-04-17 06:46:57 +02:00
Alejandro
88f46f2ab2 Merge pull request #4458 from penpot/niwinz-staging-bugfix-2
 Minor enhancements
2024-04-17 06:40:42 +02:00
Andrey Antukh
edd91f00af Add minor improvement to worker module logging 2024-04-16 23:27:00 +02:00
Andrey Antukh
6477a48a50 Merge remote-tracking branch 'origin/staging' into develop 2024-04-16 19:35:24 +02:00
Andrey Antukh
16fa0b0330 Improve email clean mechanism 2024-04-16 17:24:50 +02:00
Alejandro
c975e0bcee Merge pull request #4455 from penpot/niwinz-staging-bugfix-2
 Make some storage operations asynchronous
2024-04-16 17:01:52 +02:00
Andrey Antukh
25001e5b80 📎 Add minor logging improvements on worker module 2024-04-16 16:42:44 +02:00
Andrey Antukh
c3a0db2431 Add the ability to schedule storage object touching as a task 2024-04-16 16:42:44 +02:00
Andrey Antukh
e27c0b2086 Add a task for asynchronous object update operation 2024-04-16 16:42:44 +02:00
Pablo Alba
ec8c847440 🐛 Fix wrong permissions on shared prototype for owners 2024-04-16 13:12:21 +02:00
Ikko Eltociear Ashimine
64ff6d05c0 🐛 Fix alt typo
Communnity -> Community
2024-04-16 13:01:11 +02:00
Alejandro Alonso
ea42669ff6 Merge remote-tracking branch 'origin/staging' into develop 2024-04-16 12:42:20 +02:00
Alejandro Alonso
b14b8f794a Merge remote-tracking branch 'origin/staging' into develop 2024-04-15 20:58:22 +02:00
Alejandro Alonso
87927a3476 Merge remote-tracking branch 'origin/staging' into develop 2024-04-15 16:47:06 +02:00
Pablo Alba
acc1fac8de 🐛 Fix color picker names are not displayed correctly on their tooltips 2024-04-15 16:07:05 +02:00
Andrey Antukh
83f8218bf3 🐛 Fix incorrect queryparams handling on default nginx entrypoint 2024-04-12 10:50:13 +02:00
Andrey Antukh
c9fbb21924 Don't stop start-tmux if playwright is not found on frontend 2024-04-12 10:08:15 +02:00
Andrey Antukh
bc279977d5 📎 Comment playwright installation on frontend directory 2024-04-12 09:58:40 +02:00
Andrey Antukh
ca640964d1 ⬆️ Update exporter dependencies 2024-04-12 09:58:07 +02:00
Belén Albeza
4d29bff9b5 Add playwright to the frontend 2024-04-11 14:05:16 +02:00
Alejandro Alonso
ff04877d24 Merge remote-tracking branch 'origin/staging' into develop 2024-04-11 13:33:37 +02:00
Alejandro Alonso
34d75957f0 Merge remote-tracking branch 'origin/staging' into develop 2024-04-11 12:36:45 +02:00
Alejandro Alonso
5fccc59ad5 Merge remote-tracking branch 'origin/staging' into develop 2024-04-11 10:21:04 +02:00
Alejandro Alonso
c1c0ec6f2f Merge remote-tracking branch 'origin/staging' into develop 2024-04-10 16:32:19 +02:00
Alejandro Alonso
f47991fa9c Merge remote-tracking branch 'origin/staging' into develop 2024-04-10 09:31:44 +02:00
Kelp
656e910896 📎 Remove unnecessary html tags 2024-04-09 17:55:51 +02:00
Kelp
39c35d51d3 📎 Add missing <p> 2024-04-09 17:55:51 +02:00
Kelp
5b4fcd2c80 📎 Fix small content error 2024-04-09 17:55:51 +02:00
Kelp
91ade7fe58 🐛 Fix social media links 2024-04-09 17:55:51 +02:00
Kelp
19878484a6 🐛 Fix wrong website link 2024-04-09 17:55:51 +02:00
Kelp
c27f884755 Add light and dark version of the header 2024-04-09 17:55:51 +02:00
Alejandro Alonso
19fc5fa820 Merge remote-tracking branch 'origin/staging' into develop 2024-04-09 12:56:31 +02:00
Andrey Antukh
171320d1c0 Merge remote-tracking branch 'origin/staging' into develop 2024-04-09 10:05:51 +02:00
Alejandro Alonso
3fa1d3b5fd Merge remote-tracking branch 'origin/staging' into develop 2024-04-08 16:53:28 +02:00
Andrey Antukh
fb24918fd9 Merge remote-tracking branch 'origin/staging' into develop 2024-04-08 14:07:43 +02:00
Kelp
984dacba2b Update README.md small fix 2024-04-08 11:50:55 +02:00
Kelp
93debeb272 Update README.md 2.0 2024-04-08 11:49:56 +02:00
Andrey Antukh
e813fcb9b7 Merge remote-tracking branch 'origin/staging' into develop 2024-04-04 14:19:45 +02:00
Andrey Antukh
ad0aae375b Merge remote-tracking branch 'origin/staging' into develop 2024-04-04 12:45:38 +02:00
Andrey Antukh
d20a92ce50 Merge remote-tracking branch 'origin/staging' into develop 2024-04-02 11:35:30 +02:00
Andrey Antukh
4351c221ac Merge remote-tracking branch 'origin/staging' into develop 2024-03-27 11:10:45 +01:00
Alejandro Alonso
1f5658ad1b Merge remote-tracking branch 'origin/staging' into develop 2024-03-26 09:44:10 +01:00
Alejandro
0df97d4d7d Merge pull request #4324 from penpot/alotor-bugfix-34
Bugfixes
2024-03-26 07:40:07 +01:00
alonso.torres
e10c96fa8b 🐛 Fix problem with grid edition 2024-03-25 16:10:25 +01:00
alonso.torres
4b846b17f0 🐛 Fix problem when exporting html texts 2024-03-25 15:35:04 +01:00
alonso.torres
6f2f2291c2 🐛 Fix problem when importing SVG 2024-03-25 13:12:47 +01:00
alonso.torres
33c12117cc 🐛 Fix problem with gradients and borders 2024-03-25 09:49:38 +01:00
alonso.torres
94f9551b92 🐛 Fix problem with gradient fill text 2024-03-25 09:20:12 +01:00
Andrey Antukh
259eae70c6 Merge remote-tracking branch 'origin/staging' into develop 2024-03-25 08:48:18 +01:00
Andrey Antukh
c0fa766b64 📎 Update version.txt file 2024-03-22 08:40:31 +01:00
Andrey Antukh
a79e4d7af3 Merge remote-tracking branch 'origin/staging' into develop 2024-03-22 08:40:09 +01:00
Alejandro
589fb144db Merge pull request #4272 from peterstnsz/patch-1
Update README.md
2024-03-18 10:18:41 +01:00
alonso.torres
fd4470afde Merge remote-tracking branch 'origin/staging' into develop 2024-03-18 09:59:06 +01:00
Peter
e1e05e6de8 Update README.md
Link in the footer https://kaleidos.net/products returns 404
2024-03-14 14:52:20 +00:00
Andrey Antukh
d5dbe0b594 Merge remote-tracking branch 'origin/staging' into develop 2024-03-06 12:06:52 +01:00
Andrey Antukh
0606ef1c84 Merge remote-tracking branch 'origin/staging' into develop 2024-03-05 18:53:36 +01:00
Andrey Antukh
481058b8d4 Merge remote-tracking branch 'origin/staging' into develop 2024-03-04 10:29:11 +01:00
Andrey Antukh
a109673654 Merge remote-tracking branch 'origin/staging' into develop 2024-02-29 12:53:08 +01:00
Pablo Alba
b17371d440 🐛 Fix problems on sync with components chain with reset override 2024-02-28 11:35:19 +01:00
Andrey Antukh
617edbebec Merge remote-tracking branch 'origin/staging' into develop 2024-02-28 11:25:36 +01:00
Andrey Antukh
e3f9bafb33 Merge remote-tracking branch 'origin/staging' into develop 2024-02-27 12:53:20 +01:00
Andrey Antukh
2a6589ab01 Merge remote-tracking branch 'origin/staging' into develop 2024-02-27 12:45:59 +01:00
Andrey Antukh
9e2e9f5b64 Merge remote-tracking branch 'origin/staging' into develop 2024-02-22 16:24:26 +01:00
Andrey Antukh
82dca0439a Merge remote-tracking branch 'origin/staging' into develop 2024-02-21 14:56:28 +01:00
Andrey Antukh
66f8ffb408 Merge remote-tracking branch 'origin/staging' into develop 2024-02-20 16:07:51 +01:00
Andrey Antukh
fd641e87c9 Merge remote-tracking branch 'origin/staging' into develop 2024-02-19 16:02:59 +01:00
Andrey Antukh
bec59ab3c2 Merge remote-tracking branch 'origin/staging' into develop 2024-02-16 14:30:20 +01:00
Andrey Antukh
b426db133d Merge remote-tracking branch 'origin/staging' into develop 2024-02-14 13:01:58 +01:00
Andrey Antukh
e232beeb59 Merge remote-tracking branch 'origin/staging' into develop 2024-02-12 16:13:55 +01:00
Andrey Antukh
dae277adb2 Merge remote-tracking branch 'origin/staging' into develop 2024-02-12 10:07:32 +01:00
Andrey Antukh
cdf8c5836a Merge remote-tracking branch 'origin/staging' into develop 2024-02-09 15:01:42 +01:00
Andrey Antukh
1743da7ebf Merge remote-tracking branch 'origin/staging' into develop 2024-02-09 14:57:48 +01:00
Andrey Antukh
cff44e34c3 Merge remote-tracking branch 'origin/staging' into develop 2024-02-09 09:53:13 +01:00
Andrey Antukh
740db82b6c Merge remote-tracking branch 'origin/staging' into develop 2024-02-08 09:10:06 +01:00
Andrey Antukh
4d7a572daa Merge remote-tracking branch 'origin/staging' into develop 2024-02-06 20:10:55 +01:00
Andrey Antukh
cb6db21e63 Merge remote-tracking branch 'origin/staging' into develop 2024-02-06 09:38:25 +01:00
Andrey Antukh
06033ea955 Merge remote-tracking branch 'origin/staging' into develop 2024-02-02 10:15:40 +01:00
Andrey Antukh
f15caf54dd Merge remote-tracking branch 'origin/staging' into develop 2024-01-31 11:05:20 +01:00
Andrey Antukh
94ee83a120 Merge remote-tracking branch 'origin/staging' into develop 2024-01-30 19:32:44 +01:00
Andrey Antukh
cb6e3a2e3c Merge remote-tracking branch 'origin/staging' into develop 2024-01-30 15:34:50 +01:00
Andrey Antukh
8abab982e7 Merge remote-tracking branch 'origin/staging' into develop 2024-01-25 23:26:55 +01:00
Andrey Antukh
6a412c75ce Merge remote-tracking branch 'origin/staging' into develop 2024-01-24 09:00:42 +01:00
Andrey Antukh
098e33bd98 Merge remote-tracking branch 'origin/staging' into develop 2024-01-19 14:44:14 +01:00
Andrey Antukh
a5d056f254 Merge remote-tracking branch 'origin/staging' into develop 2024-01-17 09:51:47 +01:00
Andrey Antukh
aa33bb1ebf Merge remote-tracking branch 'origin/staging' into develop 2024-01-16 00:12:55 +01:00
Andrey Antukh
8a81bc11e0 Merge remote-tracking branch 'origin/staging' into develop 2024-01-15 10:10:35 +01:00
Andrey Antukh
f0ea613d47 Merge remote-tracking branch 'origin/staging' into develop 2024-01-11 16:18:17 +01:00
Andrey Antukh
725501faf9 Merge remote-tracking branch 'origin/staging' into develop 2024-01-11 10:17:52 +01:00
Andrey Antukh
470cf08134 Merge remote-tracking branch 'origin/staging' into develop 2024-01-10 11:43:01 +01:00
Andrey Antukh
e48bfb5d94 Merge remote-tracking branch 'origin/staging' into develop 2024-01-09 09:56:55 +01:00
Andrey Antukh
326f18cb66 Merge remote-tracking branch 'origin/staging' into develop 2024-01-09 08:53:46 +01:00
Andrey Antukh
5983b9cd54 Merge remote-tracking branch 'origin/staging' into develop 2024-01-08 15:27:27 +01:00
Andrey Antukh
864881721f 🐛 Fix validation of validation error on file validate ns 2024-01-05 17:59:17 +01:00
Andrey Antukh
9aff12f3c6 Merge remote-tracking branch 'origin/staging' into develop 2024-01-05 09:46:53 +01:00
914 changed files with 139882 additions and 75968 deletions

View File

@@ -22,52 +22,53 @@ jobs:
# Download and cache dependencies
- restore_cache:
keys:
- v1-dependencies-{{ checksum "backend/deps.edn" }}-{{ checksum "frontend/deps.edn"}}-{{ checksum "common/deps.edn"}}
# fallback to using the latest cache if no exact match is found
- v1-dependencies-
keys:
- v1-dependencies-{{ checksum "backend/deps.edn" }}-{{ checksum "frontend/deps.edn"}}-{{ checksum "common/deps.edn"}}
# fallback to using the latest cache if no exact match is found
- v1-dependencies-
- run: cd .clj-kondo && cat config.edn
- run: cat .cljfmt.edn
- run: clj-kondo --version
- run:
name: "fmt check backend [clj]"
name: "backend fmt check"
working_directory: "./backend"
command: |
yarn install
yarn run fmt:clj:check
- run:
name: "fmt check exporter [clj]"
name: "exporter fmt check"
working_directory: "./exporter"
command: |
yarn install
yarn run fmt:clj:check
- run:
name: "fmt check common [clj]"
name: "common fmt check"
working_directory: "./common"
command: |
yarn install
yarn run fmt:clj:check
- run:
name: "fmt check frontend [clj]"
name: "frontend fmt check"
working_directory: "./frontend"
command: |
yarn install
yarn run fmt:clj:check
yarn run fmt:js:check
- run:
name: common lint
name: "common linter check"
working_directory: "./common"
command: |
yarn install
yarn run lint:clj
- run:
name: frontend lint
name: "frontend linter check"
working_directory: "./frontend"
command: |
yarn install
@@ -75,14 +76,14 @@ jobs:
yarn run lint:clj
- run:
name: backend lint
name: "backend linter check"
working_directory: "./backend"
command: |
yarn install
yarn run lint:clj
- run:
name: exporter lint
name: "exporter linter check"
working_directory: "./exporter"
command: |
yarn install
@@ -93,7 +94,7 @@ jobs:
working_directory: "./common"
command: |
yarn test
clojure -X:dev:test :patterns '["common-tests.*-test"]'
clojure -M:dev:test
- run:
name: "frontend tests"
@@ -102,11 +103,21 @@ jobs:
yarn install
yarn test
- run:
name: "frontend integration tests"
working_directory: "./frontend"
command: |
yarn install
yarn run build:app:assets
clojure -M:dev:shadow-cljs release main
yarn playwright install --with-deps chromium
yarn e2e:test
- run:
name: "backend tests"
working_directory: "./backend"
command: |
clojure -X:dev:test :patterns '["backend-tests.*-test"]'
clojure -M:dev:test
environment:
PENPOT_TEST_DATABASE_URI: "postgresql://localhost/penpot_test"
@@ -115,7 +126,6 @@ jobs:
PENPOT_TEST_REDIS_URI: "redis://localhost/1"
- save_cache:
paths:
- ~/.m2
key: v1-dependencies-{{ checksum "backend/deps.edn" }}-{{ checksum "frontend/deps.edn"}}-{{ checksum "common/deps.edn"}}
paths:
- ~/.m2
key: v1-dependencies-{{ checksum "backend/deps.edn" }}-{{ checksum "frontend/deps.edn"}}-{{ checksum "common/deps.edn"}}

View File

@@ -3,7 +3,6 @@
promesa.core/->> clojure.core/->>
promesa.core/-> clojure.core/->
promesa.exec.csp/go-loop clojure.core/loop
rumext.v2/defc clojure.core/defn
promesa.util/with-open clojure.core/with-open
app.common.schema.generators/let clojure.core/let
app.common.data/export clojure.core/def
@@ -20,6 +19,7 @@
app.db/with-atomic hooks.export/penpot-with-atomic
potok.v2.core/reify hooks.export/potok-reify
rumext.v2/fnc hooks.export/rumext-fnc
rumext.v2/defc hooks.export/rumext-defc
rumext.v2/lazy-component hooks.export/rumext-lazycomponent
shadow.lazy/loadable hooks.export/rumext-lazycomponent
}}

View File

@@ -12,6 +12,7 @@
(def registry (atom {}))
(defn potok-reify
[{:keys [:node :filename] :as params}]
(let [[rnode rtype & other] (:children node)
@@ -66,12 +67,86 @@
(let [[cname mdata params & body] (rest (:children node))
[params body] (if (api/vector-node? mdata)
[mdata (cons params body)]
[params body])]
(let [result (api/list-node
(into [(api/token-node 'fn)
params]
(cons mdata body)))]
{:node result})))
[params body])
result (api/list-node
(into [(api/token-node 'fn) params]
(cons mdata body)))]
{:node result}))
(defn- parse-defc
[{:keys [children] :as node}]
(let [args (rest children)
[cname args]
(if (api/token-node? (first args))
[(first args) (rest args)]
(throw (ex-info "unexpected1" {})))
[docs args]
(if (api/string-node? (first args))
[(first args) (rest args)]
["" args])
[mdata args]
(if (api/map-node? (first args))
[(first args) (rest args)]
[(api/map-node []) args])
[params body]
(if (api/vector-node? (first args))
[(first args) (rest args)]
(throw (ex-info "unexpected2" {})))]
[cname docs mdata params body]))
(defn rumext-defc
[{:keys [node]}]
(let [[cname docs mdata params body] (parse-defc node)
param1 (first (:children params))
paramN (rest (:children params))
param1 (if (api/map-node? param1)
(let [param1 (into {} (comp
(partition-all 2)
(map (fn [[k v]]
[(if (api/keyword-node? k)
(:k k)
k)
(if (api/vector-node? v)
(vec (:children v))
v)])))
(:children param1))
binding (:rest param1)
param1 (if binding
(if (contains? param1 :as)
(update param1 :keys (fnil conj []) binding)
(assoc param1 :as binding))
param1)]
(->> (dissoc param1 :rest)
(mapcat (fn [[k v]]
[(if (keyword? k)
(api/keyword-node k)
k)
(if (vector? v)
(api/vector-node v)
v)]))
(api/map-node)))
param1)
result (api/list-node
(into [(api/token-node 'defn)
cname
(api/vector-node (filter some? (cons param1 paramN)))]
(cons mdata body)))]
;; (prn (api/sexpr result))
{:node result}))
(defn rumext-lazycomponent

View File

@@ -4,6 +4,7 @@
:remove-consecutive-blank-lines? false
:extra-indents {rumext.v2/fnc [[:inner 0]]
cljs.test/async [[:inner 0]]
app.common.schema/register! [[:inner 0] [:inner 1]]
promesa.exec/thread [[:inner 0]]
specify! [[:inner 0] [:inner 1]]}
}

8
.gitignore vendored
View File

@@ -48,6 +48,8 @@
/deploy
/docker/images/bundle*
/exporter/target
/frontend/.storybook/preview-body.html
/frontend/.storybook/preview-head.html
/frontend/cypress/fixtures/validuser.json
/frontend/cypress/videos/*/
/frontend/cypress/videos/*/
@@ -57,6 +59,7 @@
/frontend/package-lock.json
/frontend/resources/fonts/experiments
/frontend/resources/public/*
/frontend/storybook-static/
/frontend/target/
/other/
/scripts/
@@ -67,4 +70,7 @@
/web
clj-profiler/
node_modules
frontend/.storybook/preview-body.html
/test-results/
/playwright-report/
/blob-report/
/playwright/.cache/

View File

@@ -1,5 +1,206 @@
# CHANGELOG
## 2.2.1
### :bug: Bugs fixed
- Fix problem with Ctrl+F shortcut on the dashboard [Taiga #8876](https://tree.taiga.io/project/penpot/issue/8876)
- Fix visual problem with the font-size dropdown in assets [Taiga #8872](https://tree.taiga.io/project/penpot/issue/8872)
- Add limits for invitation RPC methods (hard limit 25 emails per request)
## 2.2.0
### :rocket: Epics and highlights
### :boom: Breaking changes & Deprecations
- Removed "merge assets" option when exporting ".svg + .json" files. After the components changes the option wasn't
working properly and we're planning to change the format soon. We think it's better to deprecate the option for the
time being.
### :heart: Community contributions (Thank you!)
- Set proper default tenant on exporter (by @june128) [#4946](https://github.com/penpot/penpot/pull/4946)
- Correct a spelling in onboarding.edn (by @n-stha) [#4936](https://github.com/penpot/penpot/pull/4936)
### :sparkles: New features
- **Tiered File Data Storage** [Taiga #8376](https://tree.taiga.io/project/penpot/us/8376)
This feature allows offloading file data that is not actively used
from the database to object storage (e.g., filesystem, S3), thereby
freeing up space in the database. It can be enabled with the
`enable-enable-tiered-file-data-storage` flag.
*(On-Premise feature, EXPERIMENTAL).*
- **JSON Interoperability for HTTP API** [Taiga #8372](https://tree.taiga.io/project/penpot/us/8372)
Enables full JSON interoperability for our HTTP API. Previously,
JSON was only barely supported for output when the
`application/json` media type was specified in the `Accept` header,
or when `_fmt=json` was passed as a query parameter. With this
update, we now offer proper bi-directional support for using our API
with plain JSON, instead of Transit.
- **Automatic File Snapshotting**
Adds the ability to automatically take and maintain a limited set of
snapshots of active files without explicit user intervention. This
feature allows on-premise administrators to recover the state of a
file from a past point in time in a limited manner.
It can be enabled with the `enable-auto-file-snapshot` flag and
configured with the following settings:
```bash
# Take snapshots every 10 update operations
PENPOT_AUTO_FILE_SNAPSHOT_EVERY=10
# Take a snapshot if it has been more than 3 hours since the file was last modified
PENPOT_AUTO_FILE_SNAPSHOT_TIMEOUT=3h
# The total number of snapshots to keep
PENPOT_AUTO_FILE_SNAPSHOT_TOTAL=10
```
Snapshots are only taken during update operations; there is NO
active background process for this.
- Add separated flag `enable-oidc-registration` for enable the
registration only for OIDC authentication backend [Github
#4882](https://github.com/penpot/penpot/issues/4882)
- Update templates in libraries & templates in dashboard modal [Taiga #8145](https://tree.taiga.io/project/penpot/us/8145)
- **Design System**
We implemented and subbed in new components from our Design System: `loader*` ([Taiga #8355](https://tree.taiga.io/project/penpot/task/8355)) and `tab-switcher*` ([Taiga #8518](https://tree.taiga.io/project/penpot/task/8518)).
- **Storybook** [Taiga #6329](https://tree.taiga.io/project/penpot/us/6329)
The Design System components are now published in a Storybook, available at `/storybook`.
### :bug: Bugs fixed
- Fix webhook checkbox position [Taiga #8634](https://tree.taiga.io/project/penpot/issue/8634)
- Fix wrong props on padding input [Taiga #8254](https://tree.taiga.io/project/penpot/issue/8254)
- Fix fill collapsed options [Taiga #8351](https://tree.taiga.io/project/penpot/issue/8351)
- Fix scroll on color picker modal [Taiga #8353](https://tree.taiga.io/project/penpot/issue/8353)
- Fix components are not dragged from the group to the assets tab [Taiga #8273](https://tree.taiga.io/project/penpot/issue/8273)
- Fix problem with SVG import [Github #4888](https://github.com/penpot/penpot/issues/4888)
- Fix problem with overlay positions in viewer [Taiga #8464](https://tree.taiga.io/project/penpot/issue/8464)
- Fix layer panel overflowing [Taiga #8665](https://tree.taiga.io/project/penpot/issue/8665)
- Fix problem when creating a component instance from grid layout [Github #4881](https://github.com/penpot/penpot/issues/4881)
- Fix problem when dismissing shared library update [Taiga #8669](https://tree.taiga.io/project/penpot/issue/8669)
- Fix visual problem with stroke cap menu [Taiga #8730](https://tree.taiga.io/project/penpot/issue/8730)
- Fix issue when exporting libraries when merging libraries [Taiga #8758](https://tree.taiga.io/project/penpot/issue/8758)
- Fix problem with comments max length [Taiga #8778](https://tree.taiga.io/project/penpot/issue/8778)
- Fix copy/paste images in Safari [Taiga #8771](https://tree.taiga.io/project/penpot/issue/8771)
- Fix swap when the copy is the only child of a group [#5075](https://github.com/penpot/penpot/issues/5075)
## 2.1.5
### :bug: Bugs fixed
- Fix broken webhooks [Taiga #8370](https://tree.taiga.io/project/penpot/issue/8370)
## 2.1.4
### :bug: Bugs fixed
- Fix json encoding on zip encoding decoding.
- Add schema validation for color changes.
- Fix render of some texts without position data.
## 2.1.3
- Don't allow registration when registration is disabled and invitation token is used [Github #4975](https://github.com/penpot/penpot/issues/4975)
## 2.1.2
### :bug: Bugs fixed
- User switch language to "zh_hant" will get 400 [Github #4884](https://github.com/penpot/penpot/issues/4884)
- Smtp config ignoring port if ssl is set [Github #4872](https://github.com/penpot/penpot/issues/4872)
- Ability to let users to authenticate with a private oidc provider only [Github #4963](https://github.com/penpot/penpot/issues/4963)
## 2.1.1
### :sparkles: New features
- Consolidate templates new order and naming [Taiga #8392](https://tree.taiga.io/project/penpot/task/8392)
### :bug: Bugs fixed
- Fix the “search” label in translations [Taiga #8402](https://tree.taiga.io/project/penpot/issue/8402)
- Fix pencil loader [Taiga #8348](https://tree.taiga.io/project/penpot/issue/8348)
- Fix several issues on the OIDC.
- Fix regression on the `email-verification` flag [Taiga #8398](https://tree.taiga.io/project/penpot/issue/8398)
## 2.1.0 - Things can only get better!
### :rocket: Epics and highlights
### :boom: Breaking changes & Deprecations
### :heart: Community contributions (Thank you!)
### :sparkles: New features
- Improve auth process [Taiga #7094](https://tree.taiga.io/project/penpot/us/7094)
- Add locking degrees increment (hold shift) on path edition [Taiga #7761](https://tree.taiga.io/project/penpot/issue/7761)
- Persistence & Concurrent Edition Enhancements [Taiga #5657](https://tree.taiga.io/project/penpot/us/5657)
- Allow library colors as recent colors [Taiga #7640](https://tree.taiga.io/project/penpot/issue/7640)
- Missing scroll in viewmode comments [Taiga #7427](https://tree.taiga.io/project/penpot/issue/7427)
- Comments in View mode should mimic the positioning behavior of the Workspace [Taiga #7346](https://tree.taiga.io/project/penpot/issue/7346)
- Misaligned input on comments [Taiga #7461](https://tree.taiga.io/project/penpot/issue/7461)
### :bug: Bugs fixed
- Fix selection rectangle appears on scroll [Taiga #7525](https://tree.taiga.io/project/penpot/issue/7525)
- Fix layer tree not expanding to the bottom edge [Taiga #7466](https://tree.taiga.io/project/penpot/issue/7466)
- Fix guides move when board is moved by inputs [Taiga #8010](https://tree.taiga.io/project/penpot/issue/8010)
- Fix clickable area of Penptot logo in the viewer [Taiga #7988](https://tree.taiga.io/project/penpot/issue/7988)
- Fix constraints dropdown when selecting multiple shapes [Taiga #7686](https://tree.taiga.io/project/penpot/issue/7686)
- Layout and scrollign fixes for the bottom palette [Taiga #7559](https://tree.taiga.io/project/penpot/issue/7559)
- Fix expand libraries when search results are present [Taiga #7876](https://tree.taiga.io/project/penpot/issue/7876)
- Fix color palette default library [Taiga #8029](https://tree.taiga.io/project/penpot/issue/8029)
- Component Library is lost after exporting/importing in .zip format [Github #4672](https://github.com/penpot/penpot/issues/4672)
- Fix problem with moving+selection not working properly [Taiga #7943](https://tree.taiga.io/project/penpot/issue/7943)
- Fix problem with flex layout fit to content not positioning correctly children [Taiga #7537](https://tree.taiga.io/project/penpot/issue/7537)
- Fix black line is displaying after show main [Taiga #7653](https://tree.taiga.io/project/penpot/issue/7653)
- Fix "Share prototypes" modal remains open [Taiga #7442](https://tree.taiga.io/project/penpot/issue/7442)
- Fix "Components visibility and opacity" [#4694](https://github.com/penpot/penpot/issues/4694)
- Fix "Attribute overrides in copies are not exported in zip file" [Taiga #8072](https://tree.taiga.io/project/penpot/issue/8072)
- Fix group not automatically selected in the Layers panel after creation [Taiga #8078](https://tree.taiga.io/project/penpot/issue/8078)
- Fix export boards loses opacity [Taiga #7592](https://tree.taiga.io/project/penpot/issue/7592)
- Fix change color on imported svg also changes the stroke alignment[Taiga #7673](https://github.com/penpot/penpot/pull/7673)
- Fix show in view mode and interactions workflow [Taiga #4711](https://github.com/penpot/penpot/pull/4711)
- Fix internal error when I set up a stroke for some objects without and with stroke [Taiga #7558](https://tree.taiga.io/project/penpot/issue/7558)
- Toolbar keeps toggling on and off on spacebar press [Taiga #7654](https://github.com/penpot/penpot/pull/7654)
- Fix toolbar keeps hiding when click outside workspace [Taiga #7776](https://tree.taiga.io/project/penpot/issue/7776)
- Fix open overlay relative to a frame [Taiga #7563](https://tree.taiga.io/project/penpot/issue/7563)
- Workspace-palette items stay hidden when opening with keyboard-shortcut [Taiga #7489](https://tree.taiga.io/project/penpot/issue/7489)
- Fix SVG attrs are not handled correctly when exporting/importing in .zip [Taiga #7920](https://tree.taiga.io/project/penpot/issue/7920)
- Fix validation error when detaching with two nested copies and a swap [Taiga #8095](https://tree.taiga.io/project/penpot/issue/8095)
- Export shapes that are rotated act a bit strange when reimported [Taiga #7585](https://tree.taiga.io/project/penpot/issue/7585)
- Penpot crashes when a new colorpicker is created while uploading an image to another instance [Taiga #8119](https://tree.taiga.io/project/penpot/issue/8119)
- Removing Underline and Strikethrough Affects the Previous Text Object [Taiga #8103](https://tree.taiga.io/project/penpot/issue/8103)
- Color library loses association with shapes when exporting/importing the document [Taiga #8132](https://tree.taiga.io/project/penpot/issue/8132)
- Fix can't collapse groups when searching in the assets tab [Taiga #8125](https://tree.taiga.io/project/penpot/issue/8125)
- Fix 'Detach instance' shortcut is not working [Taiga #8102](https://tree.taiga.io/project/penpot/issue/8102)
- Fix import file message does not detect 0 as error [Taiga #6824](https://tree.taiga.io/project/penpot/issue/6824)
- Image Color Library is not persisted when exporting/importing in .zip [Taiga #8131](https://tree.taiga.io/project/penpot/issue/8131)
- Fix export files including libraries [Taiga #8266](https://tree.taiga.io/project/penpot/issue/8266)
## 2.0.3
### :bug: Bugs fixed
- Fix chrome scrollbar styling [Taiga #7852](https://tree.taiga.io/project/penpot/issue/7852)
- Fix incorrect password encoding on create-profile manage scritp [Github #3651](https://github.com/penpot/penpot/issues/3651)
## 2.0.2
### :sparkles: Enhancements
@@ -7,6 +208,11 @@
- Fix locking contention on cron subsystem (causes backend start blocking)
- Fix locking contention on file object thumbails backend RPC calls
### :bug: Bugs fixed
- Fix color palette sorting [Taiga #7458](https://tree.taiga.io/project/penpot/issue/7458)
- Fix style scoping problem with imported SVG [Taiga #7671](https://tree.taiga.io/project/penpot/issue/7671)
## 2.0.1
@@ -14,6 +220,7 @@
- Fix different issues related to components v2 migrations including [Github #4443](https://github.com/penpot/penpot/issues/4443)
## 2.0.0 - I Just Can't Get Enough
### :rocket: Epics and highlights
@@ -28,6 +235,8 @@
### :boom: Breaking changes & Deprecations
- New strokes default to inside border [Taiga #6847](https://tree.taiga.io/project/penpot/issue/6847)
- Change default z ordering on layers in flex layout. The previous behavior was inconsistent with how HTML works and we changed it to be more consistent. Previous layers that overlapped could be hidden, the fastest way to fix this is changing the z-index property but a better way is to change the order of your layers.
### :heart: Community contributions (Thank you!)
- New Hausa, Yoruba and Igbo translations and update translation files (by All For Tech Empowerment Foundation) [Taiga #6950](https://tree.taiga.io/project/penpot/us/6950), [Taiga #6534](https://tree.taiga.io/project/penpot/us/6534)
@@ -105,7 +314,7 @@
- [REDESIGN] Panels visual separations [Taiga #6692](https://tree.taiga.io/project/penpot/us/6692)
- [REDESIGN] Onboarding slides [Taiga #6678](https://tree.taiga.io/project/penpot/us/6678)
### :bug Bugs fixed
### :bug: Bugs fixed
- Fix pixelated thumbnails [Github #3681](https://github.com/penpot/penpot/issues/3681), [Github #3661](https://github.com/penpot/penpot/issues/3661)
- Fix problem with not applying colors to boards [Github #3941](https://github.com/penpot/penpot/issues/3941)
- Fix problem with path editor undoing changes [Github #3998](https://github.com/penpot/penpot/issues/3998)
@@ -146,7 +355,7 @@
- Fix problem when changing typography assets [Github #3683](https://github.com/penpot/penpot/issues/3683)
- Internal error when you copy and paste some main components between files [Taiga #7397](https://tree.taiga.io/project/penpot/issue/7397)
- Fix toolbar disappearing [Taiga #7411](https://tree.taiga.io/project/penpot/issue/7411)
- Fix long text on tab breaks UI [Taiga Issue #7421](https://tree.taiga.io/project/penpot/issue/7421)
- Fix long text on tab breaks UI [Taiga #7421](https://tree.taiga.io/project/penpot/issue/7421)
## 1.19.5

View File

@@ -48,7 +48,7 @@ quick win.
If is going to be your first pull request, You can learn how from this
free video series:
https://egghead.io/series/how-to-contribute-to-an-open-source-project-on-github
https://egghead.io/courses/how-to-contribute-to-an-open-source-project-on-github
We will use the `easy fix` mark for tag for indicate issues that are
easy for beginners.

124
README.md
View File

@@ -2,10 +2,11 @@
[uri_license]: https://www.mozilla.org/en-US/MPL/2.0
[uri_license_image]: https://img.shields.io/badge/MPL-2.0-blue.svg
<h1 align="center">
<br>
<img src="https://penpot.app/images/readme/git-readme-header.png" alt="PENPOT">
</h1>
<picture>
<source media="(prefers-color-scheme: dark)" srcset="https://penpot.app/images/readme/github-dark-mode.png">
<source media="(prefers-color-scheme: light)" srcset="https://penpot.app/images/readme/github-light-mode.png">
<img alt="penpot header image" src="https://penpot.app/images/readme/github-light-mode.png">
</picture>
<p align="center"><a href="https://www.mozilla.org/en-US/MPL/2.0" rel="nofollow"><img src="https://camo.githubusercontent.com/3fcf3d6b678ea15fde3cf7d6af0e242160366282d62a7c182d83a50bfee3f45e/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f4d504c2d322e302d626c75652e737667" alt="License: MPL-2.0" data-canonical-src="https://img.shields.io/badge/MPL-2.0-blue.svg" style="max-width:100%;"></a>
<a href="https://gitter.im/penpot/community" rel="nofollow"><img src="https://camo.githubusercontent.com/5b0aecb33434f82a7b158eab7247544235ada0cf7eeb9ce8e52562dd67f614b7/68747470733a2f2f6261646765732e6769747465722e696d2f736572656e6f2d78797a2f636f6d6d756e6974792e737667" alt="Gitter" data-canonical-src="https://badges.gitter.im/sereno-xyz/community.svg" style="max-width:100%;"></a>
@@ -13,75 +14,89 @@
<a href="https://gitpod.io/#https://github.com/penpot/penpot" rel="nofollow"><img src="https://camo.githubusercontent.com/daadb4894128d1e19b72d80236f5959f1f2b47f9fe081373f3246131f0189f6c/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f476974706f642d72656164792d2d746f2d2d636f64652d626c75653f6c6f676f3d676974706f64" alt="Gitpod ready-to-code" data-canonical-src="https://img.shields.io/badge/Gitpod-ready--to--code-blue?logo=gitpod" style="max-width:100%;"></a></p>
<p align="center">
<a href="https://penpot.app/"><b>Website</b></a>
<a href="https://help.penpot.app/technical-guide/getting-started/"><b>Getting Started</b></a>
<a href="https://help.penpot.app/user-guide/"><b>User Guide</b></a>
<a href="https://help.penpot.app/user-guide/introduction/info/"><b>Tutorials & Info</b></a>
<a href="https://community.penpot.app/"><b>Community</b></a>
<a href="https://twitter.com/penpotapp"><b>Twitter</b></a> •
<a href="https://instagram.com/penpot.app"><b>Instagram</b></a> •
<a href="https://fosstodon.org/@penpot/"><b>Mastodon</b></a>
<a href="https://www.youtube.com/channel/UCAqS8G72uv9P5HG1IfgnQ9g"><b>Youtube</b></a>
<a href="https://penpot.app/"><b>Website</b></a>
<a href="https://help.penpot.app/technical-guide/getting-started/"><b>Getting Started</b></a>
<a href="https://help.penpot.app/user-guide/"><b>User Guide</b></a>
<a href="https://help.penpot.app/user-guide/introduction/info/"><b>Tutorials & Info</b></a>
<a href="https://community.penpot.app/"><b>Community</b></a>
</p>
<p align="center">
<a href="https://www.youtube.com/@Penpot"><b>Youtube</b></a>
<a href="https://peertube.kaleidos.net/a/penpot_app/video-channels"><b>Peertube</b></a>
<a href="https://www.linkedin.com/company/penpot/"><b>Linkedin</b></a> •
<a href="https://instagram.com/penpot.app"><b>Instagram</b></a> •
<a href="https://fosstodon.org/@penpot/"><b>Mastodon</b></a> •
<a href="https://twitter.com/penpotapp"><b>X</b></a>
</p>
![feature-readme](https://user-images.githubusercontent.com/1045247/189871786-0b44f7cf-3a0a-4445-a87b-9919ec398bf7.gif)
<br />
🎇 **Penpot Fest exceeded all expectations - it was a complete success!** 🎇 Penpot Fest is our first Design event that brought designers and developers from the Open Source communities and beyond. Watch the replay of the talks on our [Youtube channel](https://www.youtube.com/playlist?list=PLgcCPfOv5v56-fghJo2dHNBqL9zlDTslh) or [Peertube channel](https://peertube.kaleidos.net/w/p/1tWgyJTt8sKbWwCEcBimZW)
[Penpot video](https://github.com/penpot/penpot/assets/5446186/b8ad0764-585e-4ddc-b098-9b4090d337cc)
Penpot is the first **Open Source** design and prototyping platform meant for cross-domain teams. Non dependent on operating systems, Penpot is web based and works with open standards (SVG). Penpot invites designers all over the world to fall in love with open source while getting developers excited about the design process in return.
<br />
Penpot is the first **open-source** design tool for design and code collaboration. Designers can create stunning designs, interactive prototypes, design systems at scale, while developers enjoy ready-to-use code and make their workflow easy and fast. And all of this with no handoff drama.
Penpot is available on browser and [self host](https://penpot.app/self-host). Its web-based and works with open standards (SVG, CSS and HTML). And last but not least, its free!
Penpots latest [huge release 2.0](https://penpot.app/dev-diaries), takes the platform to a whole new level. This update introduces the ground-breaking [CSS Grid Layout feature](https://penpot.app/penpot-2.0), a complete UI redesign, a new Components system, and much more. Plus, it's faster and more accessible.
🎇 **Penpot Fest** is our design, code & Open Source event. Check out the highlights from [Penpot Fest 2023 edition](https://www.youtube.com/watch?v=sOpLZaK5mDc)!
## Table of contents ##
- [Why Penpot](#why-penpot)
- [Getting Started](#getting-started)
- [Community](#community)
- [Contributing](#contributing)
- [Resources](#resources)
- [License](#license)
## Why Penpot ##
Penpot makes design and prototyping accessible to every team in the world.
Penpot expresses designs as code. Designers can do their best work and see it will be beautifully implemented by developers in a two-way collaboration.
### For cross-domain teams ###
We have a clear focus on design and code teams and our capabilities reflect exactly that. The less hand-off mindset, the more fun for everyone.
### Designed for developers ###
Penpot was built to serve both designers and developers and create a fluid design-code process. You have the choice to enjoy real-time collaboration or play "solo".
### Multiplatform ###
Being web based, Penpot is not dependent on operating systems or local installations, you will only need to run a modern browser.
### Inspect mode ###
Work with ready-to-use code and make your workflow easy and fast. The inspect tab gives instant access to SVG, CSS and HTML code.
### Open Standards ###
Using SVG as no other design and prototyping tool does, Penpot files sport compatibility with most of the vectorial tools, are tech friendly and extremely easy to use on the web. We make sure you will always own your work.
### Self host your own instance ###
Provide your team or organization with a completely owned collaborative design tool. Use Penpot's cloud service or deploy your own Penpot server.
### Integrations ###
Penpot offers integration into the development toolchain, thanks to its support for webhooks and an API accessible through access tokens.
### Whats great for design ###
With Penpot you can design libraries to share and reuse; turn design elements into components and tokens to allow reusability and scalability; and build realistic user flows and interactions.
<br />
<p align="center">
<img src="https://penpot.app/images/readme/git-open.png" alt="Open Source" style="width: 65%;">
<img src="https://img.plasmic.app/img-optimizer/v1/img?src=https%3A%2F%2Fimg.plasmic.app%2Fimg-optimizer%2Fv1%2Fimg%2F9dd677c36afb477e9666ccd1d3f009ad.png" alt="Open Source" style="width: 65%;">
</p>
<br />
## Getting started ##
### Install with Elestio ###
[Elestio](https://elest.io/) offers a fully managed service for on-premise instances of a selection of open-source software! This means you can deploy a dedicated instance of Penpot in just 3 minutes with no technical knowledge needed.
Penpot is the only design & prototype platform that is deployment agnostic. You can use it or deploy it anywhere.
You dont need to worry about DNS configuration, SMTP, backups, SSL certificates, OS & Penpot upgrades, and much more.
[Get started with Elestio.](https://help.penpot.app/technical-guide/getting-started/#install-with-elestio)
### Install with Docker ###
You can also get started with Penpot locally or self-host it with **docker** and **docker-compose**.
Heres a step-by-step guide on [getting started with Docker.](https://help.penpot.app/technical-guide/getting-started/#install-with-docker)
### Penpot cloud app ###
If you prefer not to install Penpot in a local environment, [login or register on our Penpot cloud app](https://design.penpot.app). Create a team to work together on projects and share design assets or jump right away into Penpot and **start designing** on your own.
Learn how to install it with Elestio and Docker, or other options on [our website](https://penpot.app/self-host).
<br />
<p align="center">
<img src="https://penpot.app/images/readme/git-self-host.png" alt="Getting started" style="width: 65%;">
<img src="https://site-assets.plasmic.app/2168cf524dd543caeff32384eb9ea0a1.svg" alt="Open Source" style="width: 65%;">
</p>
<br />
## Community ##
We love the open source software community. Contributing is our passion and if its yours too, [participate](https://community.penpot.app/) and [improve](https://community.penpot.app/c/help-us-improve-penpot/7) Penpot. All your ideas and code are welcome!
We love the Open Source software community. Contributing is our passion and if its yours too, participate and [improve](https://community.penpot.app/c/help-us-improve-penpot/7) Penpot. All your designs, code and ideas are welcome!
If you need help or have any questions; if youd like to share your experience using Penpot or get inspired; if youd rather meet our community of developers and designers, [join our Community](https://community.penpot.app/)!
@@ -93,30 +108,41 @@ You will find the following categories:
- [Events and Announcements](https://community.penpot.app/c/announcements/5)
- [Inside Penpot](https://community.penpot.app/c/inside-penpot/21)
- [Penpot in your language](https://community.penpot.app/c/penpot-in-your-language/12)
- [Design and Code Essentials](https://community.penpot.app/c/design-and-code-essentials/22)
<br />
<p align="center">
<img src="https://penpot.app/images/readme/git-collaborate.png" alt="Communnity" style="width: 65%;">
<img src="https://github.com/penpot/penpot/assets/5446186/6ac62220-a16c-46c9-ab21-d24ae357ed03" alt="Community" style="width: 65%;">
</p>
<br />
## Contributing ##
Every sort of contribution will be very helpful to enhance Penpot. How youll participate? All your ideas, designs and code are welcome:
Any contribution will make a difference to improve Penpot. How can you get involved?
Choose your way:
- Create and [share Libraries & Templates](https://penpot.app/libraries-templates.html) that will be helpful for the community
- Invite your [team to join](https://design.penpot.app/#/auth/register)
- Star this repo and follow us on Social Media: [Twitter](https://twitter.com/penpotapp), [Instagram](https://instagram.com/penpot.app), [Youtube](https://www.youtube.com/c/Penpot) or [Mastodon](https://fosstodon.org/@penpot/).
- Participate in the [Community](https://community.penpot.app/) asking and answering questions, reacting to others articles or opening your own conversations.
- Star this repo and follow us on Social Media: [Mastodon](https://fosstodon.org/@penpot/), [Youtube](https://www.youtube.com/c/Penpot), [Instagram](https://instagram.com/penpot.app), [Linkedin](https://www.linkedin.com/company/penpotdesign), [Peertube](https://peertube.kaleidos.net/a/penpot_app) and [X](https://twitter.com/penpotapp).
- Participate in the [Community](https://community.penpot.app/) space by asking and answering questions; reacting to others articles; opening your own conversations and following along on decisions affecting the project.
- Report bugs with our easy [guide for bugs hunting](https://help.penpot.app/contributing-guide/reporting-bugs/) or [GitHub issues](https://github.com/penpot/penpot/issues)
- Create and [share Libraries & templates](https://penpot.app/libraries-templates.html) that will be helpful for the community
- Become a [translator](https://help.penpot.app/contributing-guide/translations)
- Give feedback: [Mail us](mailto:support@penpot.app)
- Give feedback: [Email us](mailto:support@penpot.app)
- **Contribute to Penpot's code:** [Watch this video](https://www.youtube.com/watch?v=TpN0osiY-8k) by Alejandro Alonso, CIO and developer at Penpot, where he gives us a hands-on demo of how to use Penpots repository and make changes in both front and back end
To find (almost) everything you need to know on how to contribute to Penpot, refer to the [contributing-guide](https://help.penpot.app/contributing-guide/).
To find (almost) everything you need to know on how to contribute to Penpot, refer to the [contributing guide](https://help.penpot.app/contributing-guide/).
<br />
<p align="center">
<img src="https://penpot.app/images/readme/git-community.png" alt="Contributing" style="width: 65%;">
<img src="https://github.com/penpot/penpot/assets/5446186/fea18923-dc06-49be-86ad-c3496a7956e6" alt="Libraries and templates" style="width: 65%;">
</p>
<br />
## Resources ##
You can ask and answer questions, have open-ended conversations, and follow along on decisions affecting the project.
@@ -141,4 +167,4 @@ file, You can obtain one at http://mozilla.org/MPL/2.0/.
Copyright (c) KALEIDOS INC
```
Penpot is a Kaleidos [open source project](https://kaleidos.net/products)
Penpot is a Kaleidos [open source project](https://kaleidos.net/)

View File

@@ -2,12 +2,19 @@
We want to thank to the amazing people that help us! Thank you! You're the best!
Feel free you make a PR updating this file if you miss you in the
list.
## Security
* Husnain Iqbal (CEO OF ALPHA INFERNO PVT LTD)
* [Shiraz Ali Khan](https://www.linkedin.com/in/shiraz-ali-khan-1ba508180/)
* Vaibhav Shukla
* Hassan Ahmed (Alias Xen Lee)
* Michal Biesiada (@mbiesiad)
## Internationalization
* [00ff88](https://hosted.weblate.org/user/00ff88)
* [AhmadHB](https://hosted.weblate.org/user/AhmadHB)
* [Aimee](https://hosted.weblate.org/user/Aimee)
@@ -89,6 +96,7 @@ We want to thank to the amazing people that help us! Thank you! You're the best!
* [zcraber](https://hosted.weblate.org/user/zcraber)
## Libraries & templates
* systxema
* plumilla
* victor crespo

View File

@@ -3,10 +3,10 @@
:deps
{penpot/common {:local/root "../common"}
org.clojure/clojure {:mvn/version "1.12.0-alpha5"}
org.clojure/tools.namespace {:mvn/version "1.4.4"}
org.clojure/clojure {:mvn/version "1.12.0-alpha12"}
org.clojure/tools.namespace {:mvn/version "1.5.0"}
com.github.luben/zstd-jni {:mvn/version "1.5.5-11"}
com.github.luben/zstd-jni {:mvn/version "1.5.6-3"}
io.prometheus/simpleclient {:mvn/version "0.16.0"}
io.prometheus/simpleclient_hotspot {:mvn/version "0.16.0"}
@@ -17,7 +17,7 @@
io.prometheus/simpleclient_httpserver {:mvn/version "0.16.0"}
io.lettuce/lettuce-core {:mvn/version "6.3.0.RELEASE"}
io.lettuce/lettuce-core {:mvn/version "6.3.2.RELEASE"}
java-http-clj/java-http-clj {:mvn/version "0.4.3"}
funcool/yetti
@@ -26,13 +26,13 @@
:git/url "https://github.com/funcool/yetti.git"
:exclusions [org.slf4j/slf4j-api]}
com.github.seancorfield/next.jdbc {:mvn/version "1.3.909"}
metosin/reitit-core {:mvn/version "0.6.0"}
nrepl/nrepl {:mvn/version "1.1.0"}
cider/cider-nrepl {:mvn/version "0.44.0"}
com.github.seancorfield/next.jdbc {:mvn/version "1.3.939"}
metosin/reitit-core {:mvn/version "0.7.0"}
nrepl/nrepl {:mvn/version "1.1.2"}
cider/cider-nrepl {:mvn/version "0.48.0"}
org.postgresql/postgresql {:mvn/version "42.7.1"}
org.xerial/sqlite-jdbc {:mvn/version "3.44.1.0"}
org.postgresql/postgresql {:mvn/version "42.7.3"}
org.xerial/sqlite-jdbc {:mvn/version "3.46.0.0"}
com.zaxxer/HikariCP {:mvn/version "5.1.0"}
@@ -54,11 +54,11 @@
org.clojars.pntblnk/clj-ldap {:mvn/version "0.0.17"}
dawran6/emoji {:mvn/version "0.1.5"}
markdown-clj/markdown-clj {:mvn/version "1.11.7"}
markdown-clj/markdown-clj {:mvn/version "1.12.1"}
;; Pretty Print specs
pretty-spec/pretty-spec {:mvn/version "0.1.4"}
software.amazon.awssdk/s3 {:mvn/version "2.22.12"}
software.amazon.awssdk/s3 {:mvn/version "2.25.63"}
}
:paths ["src" "resources" "target/classes"]
@@ -74,16 +74,13 @@
:build
{:extra-deps
{io.github.clojure/tools.build {:git/tag "v0.9.5" :git/sha "24f2894"}}
{io.github.clojure/tools.build {:git/tag "v0.10.3" :git/sha "15ead66"}}
:ns-default build}
:test
{:extra-paths ["test"]
:extra-deps
{io.github.cognitect-labs/test-runner
{:git/tag "v0.5.1" :git/sha "dfb30dd"}}
:main-opts ["-m" "cognitect.test-runner"]
:exec-fn cognitect.test-runner.api/test}
{:main-opts ["-m" "kaocha.runner"]
:jvm-opts ["-Dlog4j2.configurationFile=log4j2-devenv-repl.xml"]
:extra-deps {lambdaisland/kaocha {:mvn/version "1.91.1392"}}}
:outdated
{:extra-deps {com.github.liquidz/antq {:mvn/version "RELEASE"}}

View File

@@ -20,6 +20,7 @@
[app.common.schema.desc-native :as smdn]
[app.common.schema.generators :as sg]
[app.common.spec :as us]
[app.common.json :as json]
[app.common.transit :as t]
[app.common.types.file :as ctf]
[app.common.uuid :as uuid]
@@ -29,7 +30,6 @@
[app.srepl.helpers :as srepl.helpers]
[app.srepl.main :as srepl]
[app.util.blob :as blob]
[app.util.json :as json]
[app.util.time :as dt]
[clj-async-profiler.core :as prof]
[clojure.contrib.humanize :as hum]

View File

@@ -4,19 +4,19 @@
"license": "MPL-2.0",
"author": "Kaleidos INC",
"private": true,
"packageManager": "yarn@4.0.2",
"packageManager": "yarn@4.3.1",
"repository": {
"type": "git",
"url": "https://github.com/penpot/penpot"
},
"dependencies": {
"luxon": "^3.4.2",
"sax": "^1.2.4"
"luxon": "^3.4.4",
"sax": "^1.4.1"
},
"devDependencies": {
"nodemon": "^3.0.1",
"nodemon": "^3.1.2",
"source-map-support": "^0.5.21",
"ws": "^8.13.0"
"ws": "^8.17.0"
},
"scripts": {
"fmt:clj:check": "cljfmt check --parallel=false src/ test/",

View File

@@ -168,7 +168,7 @@
<table border="0" cellpadding="0" cellspacing="0" role="presentation" style="vertical-align:top;" width="100%">
<tr>
<td align="left" style="font-size:0px;padding:10px 25px;word-break:break-word;">
<div style="font-family:Source Sans Pro, sans-serif;font-size:24px;font-weight:600;line-height:150%;text-align:left;color:#000000;">Hello {{name}}!</div>
<div style="font-family:Source Sans Pro, sans-serif;font-size:24px;font-weight:600;line-height:150%;text-align:left;color:#000000;">Hello {{name|abbreviate:25}}!</div>
</td>
</tr>
<tr>
@@ -475,4 +475,4 @@
</div>
</body>
</html>
</html>

View File

@@ -1,4 +1,4 @@
Hello {{name}}!
Hello {{name|abbreviate:25}}!
We received a request to change your current email to {{ pending-email }}.

View File

@@ -11,7 +11,7 @@
{% if profile %}
<span>
<span>Name: </span>
<span><code>{{profile.fullname}}</code></span>
<span><code>{{profile.fullname|abbreviate:25}}</code></span>
</span>
<br />
@@ -34,7 +34,7 @@
</p>
<p>
<strong>Subject:</strong><br />
<span>{{subject}}</span>
<span>{{subject|abbreviate:300}}</span>
</p>
<p>

View File

@@ -173,7 +173,7 @@
</tr>
<tr>
<td align="left" style="font-size:0px;padding:10px 25px;word-break:break-word;">
<div style="font-family:Source Sans Pro, sans-serif;font-size:16px;line-height:150%;text-align:left;color:#000000;">{{invited-by}} has invited you to join the team “{{ team }}”.</div>
<div style="font-family:Source Sans Pro, sans-serif;font-size:16px;line-height:150%;text-align:left;color:#000000;">{{invited-by|abbreviate:25}} has invited you to join the team “{{ team|abbreviate:25 }}”.</div>
</td>
</tr>
<tr>
@@ -465,4 +465,4 @@
</div>
</body>
</html>
</html>

View File

@@ -1,6 +1,6 @@
Hello!
{{invited-by}} has invited you to join the team “{{ team }}”.
{{invited-by|abbreviate:25}} has invited you to join the team “{{ team|abbreviate:25 }}”.
Accept invitation using this link:

View File

@@ -0,0 +1,518 @@
<!doctype html>
<html xmlns="http://www.w3.org/1999/xhtml" xmlns:v="urn:schemas-microsoft-com:vml"
xmlns:o="urn:schemas-microsoft-com:office:office">
<head>
<title>
</title>
<!--[if !mso]><!-- -->
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<!--<![endif]-->
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<style type="text/css">
#outlook a {
padding: 0;
}
body {
margin: 0;
padding: 0;
-webkit-text-size-adjust: 100%;
-ms-text-size-adjust: 100%;
}
table,
td {
border-collapse: collapse;
mso-table-lspace: 0pt;
mso-table-rspace: 0pt;
}
img {
border: 0;
height: auto;
line-height: 100%;
outline: none;
text-decoration: none;
-ms-interpolation-mode: bicubic;
}
p {
display: block;
margin: 13px 0;
}
</style>
<!--[if mso]>
<xml>
<o:OfficeDocumentSettings>
<o:AllowPNG/>
<o:PixelsPerInch>96</o:PixelsPerInch>
</o:OfficeDocumentSettings>
</xml>
<![endif]-->
<!--[if lte mso 11]>
<style type="text/css">
.mj-outlook-group-fix { width:100% !important; }
</style>
<![endif]-->
<!--[if !mso]><!-->
<link href="https://fonts.googleapis.com/css?family=Source%20Sans%20Pro" rel="stylesheet" type="text/css">
<style type="text/css">
@import url(https://fonts.googleapis.com/css?family=Source%20Sans%20Pro);
</style>
<!--<![endif]-->
<style type="text/css">
@media only screen and (min-width:480px) {
.mj-column-per-100 {
width: 100% !important;
max-width: 100%;
}
.mj-column-px-425 {
width: 425px !important;
max-width: 425px;
}
}
</style>
<style type="text/css">
@media only screen and (max-width:480px) {
table.mj-full-width-mobile {
width: 100% !important;
}
td.mj-full-width-mobile {
width: auto !important;
}
}
</style>
</head>
<body style="background-color:#E5E5E5;">
<div style="background-color:#E5E5E5;">
<!--[if mso | IE]>
<table
align="center" border="0" cellpadding="0" cellspacing="0" class="" style="width:600px;" width="600"
>
<tr>
<td style="line-height:0px;font-size:0px;mso-line-height-rule:exactly;">
<![endif]-->
<div style="margin:0px auto;max-width:600px;">
<table align="center" border="0" cellpadding="0" cellspacing="0" role="presentation" style="width:100%;">
<tbody>
<tr>
<td style="direction:ltr;font-size:0px;padding:0;text-align:center;">
<!--[if mso | IE]>
<table role="presentation" border="0" cellpadding="0" cellspacing="0">
<tr>
<td
class="" style="vertical-align:top;width:600px;"
>
<![endif]-->
<div class="mj-column-per-100 mj-outlook-group-fix"
style="font-size:0px;text-align:left;direction:ltr;display:inline-block;vertical-align:top;width:100%;">
<table border="0" cellpadding="0" cellspacing="0" role="presentation" style="vertical-align:top;"
width="100%">
<tr>
<td align="left" style="font-size:0px;padding:16px;word-break:break-word;">
<table border="0" cellpadding="0" cellspacing="0" role="presentation"
style="border-collapse:collapse;border-spacing:0px;">
<tbody>
<tr>
<td style="width:97px;">
<img height="32" src="{{ public-uri }}/images/email/uxbox-title.png"
style="border:0;display:block;outline:none;text-decoration:none;height:32px;width:100%;font-size:13px;"
width="97" />
</td>
</tr>
</tbody>
</table>
</td>
</tr>
</table>
</div>
<!--[if mso | IE]>
</td>
</tr>
</table>
<![endif]-->
</td>
</tr>
</tbody>
</table>
</div>
<!--[if mso | IE]>
</td>
</tr>
</table>
<table
align="center" border="0" cellpadding="0" cellspacing="0" class="" style="width:600px;" width="600"
>
<tr>
<td style="line-height:0px;font-size:0px;mso-line-height-rule:exactly;">
<![endif]-->
<div style="background:#FFFFFF;background-color:#FFFFFF;margin:0px auto;max-width:600px;">
<table align="center" border="0" cellpadding="0" cellspacing="0" role="presentation"
style="background:#FFFFFF;background-color:#FFFFFF;width:100%;">
<tbody>
<tr>
<td style="direction:ltr;font-size:0px;padding:20px 0;text-align:center;">
<!--[if mso | IE]>
<table role="presentation" border="0" cellpadding="0" cellspacing="0">
<tr>
<td
class="" style="vertical-align:top;width:600px;"
>
<![endif]-->
<div class="mj-column-per-100 mj-outlook-group-fix"
style="font-size:0px;text-align:left;direction:ltr;display:inline-block;vertical-align:top;width:100%;">
<table border="0" cellpadding="0" cellspacing="0" role="presentation" style="vertical-align:top;"
width="100%">
<tr>
<td align="left" style="font-size:0px;padding:10px 25px;word-break:break-word;">
<div
style="font-family:Source Sans Pro, sans-serif;font-size:24px;font-weight:600;line-height:150%;text-align:left;color:#000000;">
Hello!</div>
</td>
</tr>
<tr>
<td align="left" style="font-size:0px;padding:10px 25px;word-break:break-word;">
<div
style="font-family:Source Sans Pro, sans-serif;font-size:16px;line-height:150%;text-align:left;color:#000000;">
As you requested, {{invited-by|abbreviate:25}} has added you to the team “{{
team|abbreviate:25}}”.</div>
</td>
</tr>
<tr>
<td align="center" vertical-align="middle"
style="font-size:0px;padding:10px 25px;word-break:break-word;">
<table border="0" cellpadding="0" cellspacing="0" role="presentation"
style="border-collapse:separate;line-height:100%;">
<tr>
<td align="center" bgcolor="#31EFB8" role="presentation"
style="border:none;border-radius:3px;cursor:auto;mso-padding-alt:10px 25px;background:#31EFB8;"
valign="middle">
<a href="{{ public-uri }}/#/dashboard/team/{{team-id}}/projects"
style="display:inline-block;background:#31EFB8;color:#1F1F1F;font-family:Source Sans Pro, sans-serif;font-size:16px;font-weight:normal;line-height:120%;margin:0;text-decoration:none;text-transform:none;padding:10px 25px;mso-padding-alt:0px;border-radius:3px;"
target="_blank"> Go to the Team </a>
</td>
</tr>
</table>
</td>
</tr>
<tr>
<td align="left" style="font-size:0px;padding:10px 25px;word-break:break-word;">
<div
style="font-family:Source Sans Pro, sans-serif;font-size:16px;line-height:150%;text-align:left;color:#000000;">
Enjoy!</div>
</td>
</tr>
<tr>
<td align="left" style="font-size:0px;padding:10px 25px;word-break:break-word;">
<div
style="font-family:Source Sans Pro, sans-serif;font-size:16px;line-height:150%;text-align:left;color:#000000;">
The Penpot team.</div>
</td>
</tr>
</table>
</div>
<!--[if mso | IE]>
</td>
</tr>
</table>
<![endif]-->
</td>
</tr>
</tbody>
</table>
</div>
<!--[if mso | IE]>
</td>
</tr>
</table>
<table
align="center" border="0" cellpadding="0" cellspacing="0" class="" style="width:600px;" width="600"
>
<tr>
<td style="line-height:0px;font-size:0px;mso-line-height-rule:exactly;">
<![endif]-->
<div style="margin:0px auto;max-width:600px;">
<table align="center" border="0" cellpadding="0" cellspacing="0" role="presentation" style="width:100%;">
<tbody>
<tr>
<td style="direction:ltr;font-size:0px;padding:24px 0 0 0;text-align:center;">
<!--[if mso | IE]>
<table role="presentation" border="0" cellpadding="0" cellspacing="0">
<tr>
<td
class="" style="vertical-align:top;width:425px;"
>
<![endif]-->
<div class="mj-column-px-425 mj-outlook-group-fix"
style="font-size:0px;text-align:left;direction:ltr;display:inline-block;vertical-align:top;width:100%;">
<table border="0" cellpadding="0" cellspacing="0" role="presentation" style="vertical-align:top;"
width="100%">
<tr>
<td align="center" style="font-size:0px;padding:10px 25px;word-break:break-word;">
<div
style="font-family:Source Sans Pro, sans-serif;font-size:14px;line-height:150%;text-align:center;color:#64666A;">
Penpot is the first Open Source design and prototyping platform meant for cross-domain teams.
</div>
</td>
</tr>
</table>
</div>
<!--[if mso | IE]>
</td>
</tr>
</table>
<![endif]-->
</td>
</tr>
</tbody>
</table>
</div>
<!--[if mso | IE]>
</td>
</tr>
</table>
<table
align="center" border="0" cellpadding="0" cellspacing="0" class="" style="width:600px;" width="600"
>
<tr>
<td style="line-height:0px;font-size:0px;mso-line-height-rule:exactly;">
<![endif]-->
<div style="margin:0px auto;max-width:600px;">
<table align="center" border="0" cellpadding="0" cellspacing="0" role="presentation" style="width:100%;">
<tbody>
<tr>
<td style="direction:ltr;font-size:0px;padding:0;text-align:center;">
<!--[if mso | IE]>
<table role="presentation" border="0" cellpadding="0" cellspacing="0">
<tr>
<td
class="" style="vertical-align:top;width:600px;"
>
<![endif]-->
<div class="mj-column-per-100 mj-outlook-group-fix"
style="font-size:0px;text-align:left;direction:ltr;display:inline-block;vertical-align:top;width:100%;">
<table border="0" cellpadding="0" cellspacing="0" role="presentation" style="vertical-align:top;"
width="100%">
<tr>
<td align="center" style="font-size:0px;padding:10px 25px;word-break:break-word;">
<!--[if mso | IE]>
<table
align="center" border="0" cellpadding="0" cellspacing="0" role="presentation"
>
<tr>
<td>
<![endif]-->
<table align="center" border="0" cellpadding="0" cellspacing="0" role="presentation"
style="float:none;display:inline-table;">
<tr>
<td style="padding:0 8px;">
<table border="0" cellpadding="0" cellspacing="0" role="presentation"
style="border-radius:3px;width:24px;">
<tr>
<td style="font-size:0;height:24px;vertical-align:middle;width:24px;">
<a href="https://penpot.app/" target="_blank">
<img height="24" src="{{ public-uri }}/images/email/logo-uxbox.png"
style="border-radius:3px;display:block;" width="24" />
</a>
</td>
</tr>
</table>
</td>
</tr>
</table>
<!--[if mso | IE]>
</td>
<td>
<![endif]-->
<table align="center" border="0" cellpadding="0" cellspacing="0" role="presentation"
style="float:none;display:inline-table;">
<tr>
<td style="padding:0 8px;">
<table border="0" cellpadding="0" cellspacing="0" role="presentation"
style="border-radius:3px;width:24px;">
<tr>
<td style="font-size:0;height:24px;vertical-align:middle;width:24px;">
<a href="https://twitter.com/penpotapp" target="_blank">
<img height="24" src="{{ public-uri }}/images/email/logo-twitter.png"
style="border-radius:3px;display:block;" width="24" />
</a>
</td>
</tr>
</table>
</td>
</tr>
</table>
<!--[if mso | IE]>
</td>
<td>
<![endif]-->
<table align="center" border="0" cellpadding="0" cellspacing="0" role="presentation"
style="float:none;display:inline-table;">
<tr>
<td style="padding:0 8px;">
<table border="0" cellpadding="0" cellspacing="0" role="presentation"
style="border-radius:3px;width:24px;">
<tr>
<td style="font-size:0;height:24px;vertical-align:middle;width:24px;">
<a href="https://github.com/penpot/" target="_blank">
<img height="24" src="{{ public-uri }}/images/email/logo-github.png"
style="border-radius:3px;display:block;" width="24" />
</a>
</td>
</tr>
</table>
</td>
</tr>
</table>
<!--[if mso | IE]>
</td>
<td>
<![endif]-->
<table align="center" border="0" cellpadding="0" cellspacing="0" role="presentation"
style="float:none;display:inline-table;">
<tr>
<td style="padding:0 8px;">
<table border="0" cellpadding="0" cellspacing="0" role="presentation"
style="border-radius:3px;width:24px;">
<tr>
<td style="font-size:0;height:24px;vertical-align:middle;width:24px;">
<a href="https://www.instagram.com/penpot.app/" target="_blank">
<img height="24" src="{{ public-uri }}/images/email/logo-instagram.png"
style="border-radius:3px;display:block;" width="24" />
</a>
</td>
</tr>
</table>
</td>
</tr>
</table>
<!--[if mso | IE]>
</td>
<td>
<![endif]-->
<table align="center" border="0" cellpadding="0" cellspacing="0" role="presentation"
style="float:none;display:inline-table;">
<tr>
<td style="padding:0 8px;">
<table border="0" cellpadding="0" cellspacing="0" role="presentation"
style="border-radius:3px;width:24px;">
<tr>
<td style="font-size:0;height:24px;vertical-align:middle;width:24px;">
<a href="https://tree.taiga.io/project/penpot" target="_blank">
<img height="24" src="{{ public-uri }}/images/email/logo-taiga.png"
style="border-radius:3px;display:block;" width="24" />
</a>
</td>
</tr>
</table>
</td>
</tr>
</table>
<!--[if mso | IE]>
</td>
</tr>
</table>
<![endif]-->
</td>
</tr>
</table>
</div>
<!--[if mso | IE]>
</td>
</tr>
</table>
<![endif]-->
</td>
</tr>
</tbody>
</table>
</div>
<!--[if mso | IE]>
</td>
</tr>
</table>
<table
align="center" border="0" cellpadding="0" cellspacing="0" class="" style="width:600px;" width="600"
>
<tr>
<td style="line-height:0px;font-size:0px;mso-line-height-rule:exactly;">
<![endif]-->
<div style="margin:0px auto;max-width:600px;">
<table align="center" border="0" cellpadding="0" cellspacing="0" role="presentation" style="width:100%;">
<tbody>
<tr>
<td style="direction:ltr;font-size:0px;padding:0 0 24px 0;text-align:center;">
<!--[if mso | IE]>
<table role="presentation" border="0" cellpadding="0" cellspacing="0">
<tr>
<td
class="" style="vertical-align:top;width:600px;"
>
<![endif]-->
<div class="mj-column-per-100 mj-outlook-group-fix"
style="font-size:0px;text-align:left;direction:ltr;display:inline-block;vertical-align:top;width:100%;">
<table border="0" cellpadding="0" cellspacing="0" role="presentation" style="vertical-align:top;"
width="100%">
<tr>
<td align="center" style="font-size:0px;padding:10px 25px;word-break:break-word;">
<div
style="font-family:Source Sans Pro, sans-serif;font-size:14px;line-height:150%;text-align:center;color:#64666A;">
Penpot | Made with &lt;3 and Open Source</div>
</td>
</tr>
</table>
</div>
<!--[if mso | IE]>
</td>
</tr>
</table>
<![endif]-->
</td>
</tr>
</tbody>
</table>
</div>
<!--[if mso | IE]>
</td>
</tr>
</table>
<![endif]-->
</div>
</body>
</html>

View File

@@ -0,0 +1 @@
You have joined {{team}}

View File

@@ -0,0 +1,10 @@
Hello!
As you requested, {{invited-by|abbreviate:25}} has added you to the team “{{ team|abbreviate:25}}”.
Go to the team with this link:
{{ public-uri }}/#/dashboard/team/{{team-id}}
Enjoy!
The Penpot team.

View File

@@ -168,7 +168,7 @@
<table border="0" cellpadding="0" cellspacing="0" role="presentation" style="vertical-align:top;" width="100%">
<tr>
<td align="left" style="font-size:0px;padding:10px 25px;word-break:break-word;">
<div style="font-family:Source Sans Pro, sans-serif;font-size:24px;font-weight:600;line-height:150%;text-align:left;color:#000000;">Hello {{name}}!</div>
<div style="font-family:Source Sans Pro, sans-serif;font-size:24px;font-weight:600;line-height:150%;text-align:left;color:#000000;">Hello {{name|abbreviate:25}}!</div>
</td>
</tr>
<tr>
@@ -470,4 +470,4 @@
</div>
</body>
</html>
</html>

View File

@@ -1,4 +1,4 @@
Hello {{name}}!
Hello {{name|abbreviate:25}}!
We received a request to reset your password. Click the link below to choose a
new one:

View File

@@ -168,7 +168,7 @@
<table border="0" cellpadding="0" cellspacing="0" role="presentation" style="vertical-align:top;" width="100%">
<tr>
<td align="left" style="font-size:0px;padding:10px 25px;word-break:break-word;">
<div style="font-family:Source Sans Pro, sans-serif;font-size:24px;font-weight:600;line-height:150%;text-align:left;color:#000000;">Hello {{name}}!</div>
<div style="font-family:Source Sans Pro, sans-serif;font-size:24px;font-weight:600;line-height:150%;text-align:left;color:#000000;">Hello {{name|abbreviate:25}}!</div>
</td>
</tr>
<tr>

View File

@@ -1,4 +1,4 @@
Hello {{name}}!
Hello {{name|abbreviate:25}}!
Thanks for signing up for your Penpot account! Please verify your email using the
link below and get started building mockups and prototypes today!

View File

@@ -0,0 +1,528 @@
<!doctype html>
<html xmlns="http://www.w3.org/1999/xhtml" xmlns:v="urn:schemas-microsoft-com:vml"
xmlns:o="urn:schemas-microsoft-com:office:office">
<head>
<title>
</title>
<!--[if !mso]><!-- -->
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<!--<![endif]-->
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<style type="text/css">
#outlook a {
padding: 0;
}
body {
margin: 0;
padding: 0;
-webkit-text-size-adjust: 100%;
-ms-text-size-adjust: 100%;
}
table,
td {
border-collapse: collapse;
mso-table-lspace: 0pt;
mso-table-rspace: 0pt;
}
img {
border: 0;
height: auto;
line-height: 100%;
outline: none;
text-decoration: none;
-ms-interpolation-mode: bicubic;
}
p {
display: block;
margin: 13px 0;
}
</style>
<!--[if mso]>
<xml>
<o:OfficeDocumentSettings>
<o:AllowPNG/>
<o:PixelsPerInch>96</o:PixelsPerInch>
</o:OfficeDocumentSettings>
</xml>
<![endif]-->
<!--[if lte mso 11]>
<style type="text/css">
.mj-outlook-group-fix { width:100% !important; }
</style>
<![endif]-->
<!--[if !mso]><!-->
<link href="https://fonts.googleapis.com/css?family=Source%20Sans%20Pro" rel="stylesheet" type="text/css">
<style type="text/css">
@import url(https://fonts.googleapis.com/css?family=Source%20Sans%20Pro);
</style>
<!--<![endif]-->
<style type="text/css">
@media only screen and (min-width:480px) {
.mj-column-per-100 {
width: 100% !important;
max-width: 100%;
}
.mj-column-px-425 {
width: 425px !important;
max-width: 425px;
}
}
</style>
<style type="text/css">
@media only screen and (max-width:480px) {
table.mj-full-width-mobile {
width: 100% !important;
}
td.mj-full-width-mobile {
width: auto !important;
}
}
</style>
</head>
<body style="background-color:#E5E5E5;">
<div style="background-color:#E5E5E5;">
<!--[if mso | IE]>
<table
align="center" border="0" cellpadding="0" cellspacing="0" class="" style="width:600px;" width="600"
>
<tr>
<td style="line-height:0px;font-size:0px;mso-line-height-rule:exactly;">
<![endif]-->
<div style="margin:0px auto;max-width:600px;">
<table align="center" border="0" cellpadding="0" cellspacing="0" role="presentation" style="width:100%;">
<tbody>
<tr>
<td style="direction:ltr;font-size:0px;padding:0;text-align:center;">
<!--[if mso | IE]>
<table role="presentation" border="0" cellpadding="0" cellspacing="0">
<tr>
<td
class="" style="vertical-align:top;width:600px;"
>
<![endif]-->
<div class="mj-column-per-100 mj-outlook-group-fix"
style="font-size:0px;text-align:left;direction:ltr;display:inline-block;vertical-align:top;width:100%;">
<table border="0" cellpadding="0" cellspacing="0" role="presentation" style="vertical-align:top;"
width="100%">
<tr>
<td align="left" style="font-size:0px;padding:16px;word-break:break-word;">
<table border="0" cellpadding="0" cellspacing="0" role="presentation"
style="border-collapse:collapse;border-spacing:0px;">
<tbody>
<tr>
<td style="width:97px;">
<img height="32" src="{{ public-uri }}/images/email/uxbox-title.png"
style="border:0;display:block;outline:none;text-decoration:none;height:32px;width:100%;font-size:13px;"
width="97" />
</td>
</tr>
</tbody>
</table>
</td>
</tr>
</table>
</div>
<!--[if mso | IE]>
</td>
</tr>
</table>
<![endif]-->
</td>
</tr>
</tbody>
</table>
</div>
<!--[if mso | IE]>
</td>
</tr>
</table>
<table
align="center" border="0" cellpadding="0" cellspacing="0" class="" style="width:600px;" width="600"
>
<tr>
<td style="line-height:0px;font-size:0px;mso-line-height-rule:exactly;">
<![endif]-->
<div style="background:#FFFFFF;background-color:#FFFFFF;margin:0px auto;max-width:600px;">
<table align="center" border="0" cellpadding="0" cellspacing="0" role="presentation"
style="background:#FFFFFF;background-color:#FFFFFF;width:100%;">
<tbody>
<tr>
<td style="direction:ltr;font-size:0px;padding:20px 0;text-align:center;">
<!--[if mso | IE]>
<table role="presentation" border="0" cellpadding="0" cellspacing="0">
<tr>
<td
class="" style="vertical-align:top;width:600px;"
>
<![endif]-->
<div class="mj-column-per-100 mj-outlook-group-fix"
style="font-size:0px;text-align:left;direction:ltr;display:inline-block;vertical-align:top;width:100%;">
<table border="0" cellpadding="0" cellspacing="0" role="presentation" style="vertical-align:top;"
width="100%">
<tr>
<td align="left" style="font-size:0px;padding:10px 25px;word-break:break-word;">
<div
style="font-family:Source Sans Pro, sans-serif;font-size:24px;font-weight:600;line-height:150%;text-align:left;color:#000000;">
Hello!</div>
</td>
</tr>
<tr>
<td align="left" style="font-size:0px;padding:10px 25px;word-break:break-word;">
<div
style="font-family:Source Sans Pro, sans-serif;font-size:16px;line-height:150%;text-align:left;color:#000000;">
<p>
{{requested-by|abbreviate:25}} ({{requested-by-email}}) wants to have view-only access to the
file named “{{file-name|abbreviate:25}}”.
</p>
<p>
Since this file is in your Penpot team, you can provide access by sending a view-only link.
This will allow {{requested-by|abbreviate:25}} to view the content without making any changes.
</p>
<p>To proceed, please click the button below to generate and send the view-only link:</p>
</div>
</td>
</tr>
<tr>
<td align="center" vertical-align="middle"
style="font-size:0px;padding:10px 25px;word-break:break-word;">
<table border="0" cellpadding="0" cellspacing="0" role="presentation"
style="border-collapse:separate;line-height:100%">
<tr>
<td align="center" bgcolor="#31EFB8" role="presentation"
style="border:none;border-radius:3px;cursor:auto;mso-padding-alt:10px 25px;background:#31EFB8;"
valign="middle">
<a href="{{ public-uri }}/#/view/{{file-id}}?page-id={{page-id}}&section=interactions&index=0&share=true"
style="display:inline-block;background:#31EFB8;color:#1F1F1F;font-family:Source Sans Pro, sans-serif;font-size:16px;font-weight:normal;line-height:120%;margin:0;text-decoration:none;text-transform:none;padding:10px 25px;mso-padding-alt:0px;border-radius:3px;"
target="_blank"> Send a View-Only link </a>
</td>
</tr>
</table>
</td>
</tr>
<tr>
<td align="left" style="font-size:0px;padding:10px 25px;word-break:break-word;">
<div
style="font-family:Source Sans Pro, sans-serif;font-size:16px;line-height:150%;text-align:left;color:#000000;">
<p>If you do not wish to grant access at this time, you can simply disregard this email.</p>
<p>Thank you</p>
</div>
</td>
</tr>
<tr>
<td align="left" style="font-size:0px;padding:10px 25px;word-break:break-word;">
<div
style="font-family:Source Sans Pro, sans-serif;font-size:16px;line-height:150%;text-align:left;color:#000000;">
The Penpot team.</div>
</td>
</tr>
</table>
</div>
<!--[if mso | IE]>
</td>
</tr>
</table>
<![endif]-->
</td>
</tr>
</tbody>
</table>
</div>
<!--[if mso | IE]>
</td>
</tr>
</table>
<table
align="center" border="0" cellpadding="0" cellspacing="0" class="" style="width:600px;" width="600"
>
<tr>
<td style="line-height:0px;font-size:0px;mso-line-height-rule:exactly;">
<![endif]-->
<div style="margin:0px auto;max-width:600px;">
<table align="center" border="0" cellpadding="0" cellspacing="0" role="presentation" style="width:100%;">
<tbody>
<tr>
<td style="direction:ltr;font-size:0px;padding:24px 0 0 0;text-align:center;">
<!--[if mso | IE]>
<table role="presentation" border="0" cellpadding="0" cellspacing="0">
<tr>
<td
class="" style="vertical-align:top;width:425px;"
>
<![endif]-->
<div class="mj-column-px-425 mj-outlook-group-fix"
style="font-size:0px;text-align:left;direction:ltr;display:inline-block;vertical-align:top;width:100%;">
<table border="0" cellpadding="0" cellspacing="0" role="presentation" style="vertical-align:top;"
width="100%">
<tr>
<td align="center" style="font-size:0px;padding:10px 25px;word-break:break-word;">
<div
style="font-family:Source Sans Pro, sans-serif;font-size:14px;line-height:150%;text-align:center;color:#64666A;">
Penpot is the first Open Source design and prototyping platform meant for cross-domain teams.
</div>
</td>
</tr>
</table>
</div>
<!--[if mso | IE]>
</td>
</tr>
</table>
<![endif]-->
</td>
</tr>
</tbody>
</table>
</div>
<!--[if mso | IE]>
</td>
</tr>
</table>
<table
align="center" border="0" cellpadding="0" cellspacing="0" class="" style="width:600px;" width="600"
>
<tr>
<td style="line-height:0px;font-size:0px;mso-line-height-rule:exactly;">
<![endif]-->
<div style="margin:0px auto;max-width:600px;">
<table align="center" border="0" cellpadding="0" cellspacing="0" role="presentation" style="width:100%;">
<tbody>
<tr>
<td style="direction:ltr;font-size:0px;padding:0;text-align:center;">
<!--[if mso | IE]>
<table role="presentation" border="0" cellpadding="0" cellspacing="0">
<tr>
<td
class="" style="vertical-align:top;width:600px;"
>
<![endif]-->
<div class="mj-column-per-100 mj-outlook-group-fix"
style="font-size:0px;text-align:left;direction:ltr;display:inline-block;vertical-align:top;width:100%;">
<table border="0" cellpadding="0" cellspacing="0" role="presentation" style="vertical-align:top;"
width="100%">
<tr>
<td align="center" style="font-size:0px;padding:10px 25px;word-break:break-word;">
<!--[if mso | IE]>
<table
align="center" border="0" cellpadding="0" cellspacing="0" role="presentation"
>
<tr>
<td>
<![endif]-->
<table align="center" border="0" cellpadding="0" cellspacing="0" role="presentation"
style="float:none;display:inline-table;">
<tr>
<td style="padding:0 8px;">
<table border="0" cellpadding="0" cellspacing="0" role="presentation"
style="border-radius:3px;width:24px;">
<tr>
<td style="font-size:0;height:24px;vertical-align:middle;width:24px;">
<a href="https://penpot.app/" target="_blank">
<img height="24" src="{{ public-uri }}/images/email/logo-uxbox.png"
style="border-radius:3px;display:block;" width="24" />
</a>
</td>
</tr>
</table>
</td>
</tr>
</table>
<!--[if mso | IE]>
</td>
<td>
<![endif]-->
<table align="center" border="0" cellpadding="0" cellspacing="0" role="presentation"
style="float:none;display:inline-table;">
<tr>
<td style="padding:0 8px;">
<table border="0" cellpadding="0" cellspacing="0" role="presentation"
style="border-radius:3px;width:24px;">
<tr>
<td style="font-size:0;height:24px;vertical-align:middle;width:24px;">
<a href="https://twitter.com/penpotapp" target="_blank">
<img height="24" src="{{ public-uri }}/images/email/logo-twitter.png"
style="border-radius:3px;display:block;" width="24" />
</a>
</td>
</tr>
</table>
</td>
</tr>
</table>
<!--[if mso | IE]>
</td>
<td>
<![endif]-->
<table align="center" border="0" cellpadding="0" cellspacing="0" role="presentation"
style="float:none;display:inline-table;">
<tr>
<td style="padding:0 8px;">
<table border="0" cellpadding="0" cellspacing="0" role="presentation"
style="border-radius:3px;width:24px;">
<tr>
<td style="font-size:0;height:24px;vertical-align:middle;width:24px;">
<a href="https://github.com/penpot/" target="_blank">
<img height="24" src="{{ public-uri }}/images/email/logo-github.png"
style="border-radius:3px;display:block;" width="24" />
</a>
</td>
</tr>
</table>
</td>
</tr>
</table>
<!--[if mso | IE]>
</td>
<td>
<![endif]-->
<table align="center" border="0" cellpadding="0" cellspacing="0" role="presentation"
style="float:none;display:inline-table;">
<tr>
<td style="padding:0 8px;">
<table border="0" cellpadding="0" cellspacing="0" role="presentation"
style="border-radius:3px;width:24px;">
<tr>
<td style="font-size:0;height:24px;vertical-align:middle;width:24px;">
<a href="https://www.instagram.com/penpot.app/" target="_blank">
<img height="24" src="{{ public-uri }}/images/email/logo-instagram.png"
style="border-radius:3px;display:block;" width="24" />
</a>
</td>
</tr>
</table>
</td>
</tr>
</table>
<!--[if mso | IE]>
</td>
<td>
<![endif]-->
<table align="center" border="0" cellpadding="0" cellspacing="0" role="presentation"
style="float:none;display:inline-table;">
<tr>
<td style="padding:0 8px;">
<table border="0" cellpadding="0" cellspacing="0" role="presentation"
style="border-radius:3px;width:24px;">
<tr>
<td style="font-size:0;height:24px;vertical-align:middle;width:24px;">
<a href="https://tree.taiga.io/project/penpot" target="_blank">
<img height="24" src="{{ public-uri }}/images/email/logo-taiga.png"
style="border-radius:3px;display:block;" width="24" />
</a>
</td>
</tr>
</table>
</td>
</tr>
</table>
<!--[if mso | IE]>
</td>
</tr>
</table>
<![endif]-->
</td>
</tr>
</table>
</div>
<!--[if mso | IE]>
</td>
</tr>
</table>
<![endif]-->
</td>
</tr>
</tbody>
</table>
</div>
<!--[if mso | IE]>
</td>
</tr>
</table>
<table
align="center" border="0" cellpadding="0" cellspacing="0" class="" style="width:600px;" width="600"
>
<tr>
<td style="line-height:0px;font-size:0px;mso-line-height-rule:exactly;">
<![endif]-->
<div style="margin:0px auto;max-width:600px;">
<table align="center" border="0" cellpadding="0" cellspacing="0" role="presentation" style="width:100%;">
<tbody>
<tr>
<td style="direction:ltr;font-size:0px;padding:0 0 24px 0;text-align:center;">
<!--[if mso | IE]>
<table role="presentation" border="0" cellpadding="0" cellspacing="0">
<tr>
<td
class="" style="vertical-align:top;width:600px;"
>
<![endif]-->
<div class="mj-column-per-100 mj-outlook-group-fix"
style="font-size:0px;text-align:left;direction:ltr;display:inline-block;vertical-align:top;width:100%;">
<table border="0" cellpadding="0" cellspacing="0" role="presentation" style="vertical-align:top;"
width="100%">
<tr>
<td align="center" style="font-size:0px;padding:10px 25px;word-break:break-word;">
<div
style="font-family:Source Sans Pro, sans-serif;font-size:14px;line-height:150%;text-align:center;color:#64666A;">
Penpot | Made with &lt;3 and Open Source</div>
</td>
</tr>
</table>
</div>
<!--[if mso | IE]>
</td>
</tr>
</table>
<![endif]-->
</td>
</tr>
</tbody>
</table>
</div>
<!--[if mso | IE]>
</td>
</tr>
</table>
<![endif]-->
</div>
</body>
</html>

View File

@@ -0,0 +1 @@
Request View-Only Access to “{{file-name|abbreviate:25}}”

View File

@@ -0,0 +1,17 @@
Hello!
{{requested-by|abbreviate:25}} ({{requested-by-email}}) wants to have view-only access to the file named “{{file-name|abbreviate:25}}”.
Since this file is in your Penpot team, you can provide access by sending a view-only link. This will allow {{requested-by|abbreviate:25}} to view the content without making any changes.
To proceed, please click the link below to generate and send the view-only link:
{{ public-uri }}/#/view/{{file-id}}?page-id={{page-id}}&section=interactions&index=0&share=true
If you do not wish to grant access at this time, you can simply disregard this email.
Thank you
The Penpot team.

View File

@@ -0,0 +1,551 @@
<!doctype html>
<html xmlns="http://www.w3.org/1999/xhtml" xmlns:v="urn:schemas-microsoft-com:vml"
xmlns:o="urn:schemas-microsoft-com:office:office">
<head>
<title>
</title>
<!--[if !mso]><!-- -->
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<!--<![endif]-->
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<style type="text/css">
#outlook a {
padding: 0;
}
body {
margin: 0;
padding: 0;
-webkit-text-size-adjust: 100%;
-ms-text-size-adjust: 100%;
}
table,
td {
border-collapse: collapse;
mso-table-lspace: 0pt;
mso-table-rspace: 0pt;
}
img {
border: 0;
height: auto;
line-height: 100%;
outline: none;
text-decoration: none;
-ms-interpolation-mode: bicubic;
}
p {
display: block;
margin: 13px 0;
}
</style>
<!--[if mso]>
<xml>
<o:OfficeDocumentSettings>
<o:AllowPNG/>
<o:PixelsPerInch>96</o:PixelsPerInch>
</o:OfficeDocumentSettings>
</xml>
<![endif]-->
<!--[if lte mso 11]>
<style type="text/css">
.mj-outlook-group-fix { width:100% !important; }
</style>
<![endif]-->
<!--[if !mso]><!-->
<link href="https://fonts.googleapis.com/css?family=Source%20Sans%20Pro" rel="stylesheet" type="text/css">
<style type="text/css">
@import url(https://fonts.googleapis.com/css?family=Source%20Sans%20Pro);
</style>
<!--<![endif]-->
<style type="text/css">
@media only screen and (min-width:480px) {
.mj-column-per-100 {
width: 100% !important;
max-width: 100%;
}
.mj-column-px-425 {
width: 425px !important;
max-width: 425px;
}
}
</style>
<style type="text/css">
@media only screen and (max-width:480px) {
table.mj-full-width-mobile {
width: 100% !important;
}
td.mj-full-width-mobile {
width: auto !important;
}
}
</style>
</head>
<body style="background-color:#E5E5E5;">
<div style="background-color:#E5E5E5;">
<!--[if mso | IE]>
<table
align="center" border="0" cellpadding="0" cellspacing="0" class="" style="width:600px;" width="600"
>
<tr>
<td style="line-height:0px;font-size:0px;mso-line-height-rule:exactly;">
<![endif]-->
<div style="margin:0px auto;max-width:600px;">
<table align="center" border="0" cellpadding="0" cellspacing="0" role="presentation" style="width:100%;">
<tbody>
<tr>
<td style="direction:ltr;font-size:0px;padding:0;text-align:center;">
<!--[if mso | IE]>
<table role="presentation" border="0" cellpadding="0" cellspacing="0">
<tr>
<td
class="" style="vertical-align:top;width:600px;"
>
<![endif]-->
<div class="mj-column-per-100 mj-outlook-group-fix"
style="font-size:0px;text-align:left;direction:ltr;display:inline-block;vertical-align:top;width:100%;">
<table border="0" cellpadding="0" cellspacing="0" role="presentation" style="vertical-align:top;"
width="100%">
<tr>
<td align="left" style="font-size:0px;padding:16px;word-break:break-word;">
<table border="0" cellpadding="0" cellspacing="0" role="presentation"
style="border-collapse:collapse;border-spacing:0px;">
<tbody>
<tr>
<td style="width:97px;">
<img height="32" src="{{ public-uri }}/images/email/uxbox-title.png"
style="border:0;display:block;outline:none;text-decoration:none;height:32px;width:100%;font-size:13px;"
width="97" />
</td>
</tr>
</tbody>
</table>
</td>
</tr>
</table>
</div>
<!--[if mso | IE]>
</td>
</tr>
</table>
<![endif]-->
</td>
</tr>
</tbody>
</table>
</div>
<!--[if mso | IE]>
</td>
</tr>
</table>
<table
align="center" border="0" cellpadding="0" cellspacing="0" class="" style="width:600px;" width="600"
>
<tr>
<td style="line-height:0px;font-size:0px;mso-line-height-rule:exactly;">
<![endif]-->
<div style="background:#FFFFFF;background-color:#FFFFFF;margin:0px auto;max-width:600px;">
<table align="center" border="0" cellpadding="0" cellspacing="0" role="presentation"
style="background:#FFFFFF;background-color:#FFFFFF;width:100%;">
<tbody>
<tr>
<td style="direction:ltr;font-size:0px;padding:20px 0;text-align:center;">
<!--[if mso | IE]>
<table role="presentation" border="0" cellpadding="0" cellspacing="0">
<tr>
<td
class="" style="vertical-align:top;width:600px;"
>
<![endif]-->
<div class="mj-column-per-100 mj-outlook-group-fix"
style="font-size:0px;text-align:left;direction:ltr;display:inline-block;vertical-align:top;width:100%;">
<table border="0" cellpadding="0" cellspacing="0" role="presentation" style="vertical-align:top;"
width="100%">
<tr>
<td align="left" style="font-size:0px;padding:10px 25px;word-break:break-word;">
<div
style="font-family:Source Sans Pro, sans-serif;font-size:24px;font-weight:600;line-height:150%;text-align:left;color:#000000;">
Hello!</div>
</td>
</tr>
<tr>
<td align="left" style="font-size:0px;padding:10px 25px;word-break:break-word;">
<div
style="font-family:Source Sans Pro, sans-serif;font-size:16px;line-height:150%;text-align:left;color:#000000;">
<p>
{{requested-by|abbreviate:25}} ({{requested-by-email}}) has requested access to the file named
“{{file-name|abbreviate:25}}”.
</p>
<p>
Please note that the file is currently in Your Penpot 's team, so direct access cannot be
granted. However, you have two options to provide the requested access:
</p>
<ul>
<li>
<p>Move the File to Another Team:</p>
<p>You can move the file to another team and then give access to that team, inviting
{{requested-by|abbreviate:25}}.</p>
</li>
</ul>
</p>
</div>
</td>
</tr>
<tr>
<td align="left" style="font-size:0px;padding:10px 25px;word-break:break-word;">
<div
style="font-family:Source Sans Pro, sans-serif;font-size:16px;line-height:150%;text-align:left;color:#000000;">
<ul>
<li>
<p>Send a View-Only Link:</p>
<p>Alternatively, you can create and share a view-only link to the file. This will allow
{{requested-by|abbreviate:25}} to view the content without making any changes.</p>
<p>Click the button below to generate and send the link:</p>
</li>
</ul>
</p>
</div>
</td>
</tr>
<tr>
<td align="center" vertical-align="middle"
style="font-size:0px;padding:10px 25px;word-break:break-word;">
<table border="0" cellpadding="0" cellspacing="0" role="presentation"
style="border-collapse:separate;line-height:100%">
<tr>
<td align="center" bgcolor="#31EFB8" role="presentation"
style="border:none;border-radius:3px;cursor:auto;mso-padding-alt:10px 25px;background:#31EFB8;"
valign="middle">
<a href="{{ public-uri }}/#/view/{{file-id}}?page-id={{page-id}}&section=interactions&index=0&share=true"
style="display:inline-block;background:#31EFB8;color:#1F1F1F;font-family:Source Sans Pro, sans-serif;font-size:16px;font-weight:normal;line-height:120%;margin:0;text-decoration:none;text-transform:none;padding:10px 25px;mso-padding-alt:0px;border-radius:3px;"
target="_blank"> Send a View-Only link </a>
</td>
</tr>
</table>
</td>
</tr>
<tr>
<td align="left" style="font-size:0px;padding:10px 25px;word-break:break-word;">
<div
style="font-family:Source Sans Pro, sans-serif;font-size:16px;line-height:150%;text-align:left;color:#000000;">
<p>If you do not wish to grant access at this time, you can simply disregard this email.</p>
<p>Thank you</p>
</div>
</td>
</tr>
<tr>
<td align="left" style="font-size:0px;padding:10px 25px;word-break:break-word;">
<div
style="font-family:Source Sans Pro, sans-serif;font-size:16px;line-height:150%;text-align:left;color:#000000;">
The Penpot team.</div>
</td>
</tr>
</table>
</div>
<!--[if mso | IE]>
</td>
</tr>
</table>
<![endif]-->
</td>
</tr>
</tbody>
</table>
</div>
<!--[if mso | IE]>
</td>
</tr>
</table>
<table
align="center" border="0" cellpadding="0" cellspacing="0" class="" style="width:600px;" width="600"
>
<tr>
<td style="line-height:0px;font-size:0px;mso-line-height-rule:exactly;">
<![endif]-->
<div style="margin:0px auto;max-width:600px;">
<table align="center" border="0" cellpadding="0" cellspacing="0" role="presentation" style="width:100%;">
<tbody>
<tr>
<td style="direction:ltr;font-size:0px;padding:24px 0 0 0;text-align:center;">
<!--[if mso | IE]>
<table role="presentation" border="0" cellpadding="0" cellspacing="0">
<tr>
<td
class="" style="vertical-align:top;width:425px;"
>
<![endif]-->
<div class="mj-column-px-425 mj-outlook-group-fix"
style="font-size:0px;text-align:left;direction:ltr;display:inline-block;vertical-align:top;width:100%;">
<table border="0" cellpadding="0" cellspacing="0" role="presentation" style="vertical-align:top;"
width="100%">
<tr>
<td align="center" style="font-size:0px;padding:10px 25px;word-break:break-word;">
<div
style="font-family:Source Sans Pro, sans-serif;font-size:14px;line-height:150%;text-align:center;color:#64666A;">
Penpot is the first Open Source design and prototyping platform meant for cross-domain teams.
</div>
</td>
</tr>
</table>
</div>
<!--[if mso | IE]>
</td>
</tr>
</table>
<![endif]-->
</td>
</tr>
</tbody>
</table>
</div>
<!--[if mso | IE]>
</td>
</tr>
</table>
<table
align="center" border="0" cellpadding="0" cellspacing="0" class="" style="width:600px;" width="600"
>
<tr>
<td style="line-height:0px;font-size:0px;mso-line-height-rule:exactly;">
<![endif]-->
<div style="margin:0px auto;max-width:600px;">
<table align="center" border="0" cellpadding="0" cellspacing="0" role="presentation" style="width:100%;">
<tbody>
<tr>
<td style="direction:ltr;font-size:0px;padding:0;text-align:center;">
<!--[if mso | IE]>
<table role="presentation" border="0" cellpadding="0" cellspacing="0">
<tr>
<td
class="" style="vertical-align:top;width:600px;"
>
<![endif]-->
<div class="mj-column-per-100 mj-outlook-group-fix"
style="font-size:0px;text-align:left;direction:ltr;display:inline-block;vertical-align:top;width:100%;">
<table border="0" cellpadding="0" cellspacing="0" role="presentation" style="vertical-align:top;"
width="100%">
<tr>
<td align="center" style="font-size:0px;padding:10px 25px;word-break:break-word;">
<!--[if mso | IE]>
<table
align="center" border="0" cellpadding="0" cellspacing="0" role="presentation"
>
<tr>
<td>
<![endif]-->
<table align="center" border="0" cellpadding="0" cellspacing="0" role="presentation"
style="float:none;display:inline-table;">
<tr>
<td style="padding:0 8px;">
<table border="0" cellpadding="0" cellspacing="0" role="presentation"
style="border-radius:3px;width:24px;">
<tr>
<td style="font-size:0;height:24px;vertical-align:middle;width:24px;">
<a href="https://penpot.app/" target="_blank">
<img height="24" src="{{ public-uri }}/images/email/logo-uxbox.png"
style="border-radius:3px;display:block;" width="24" />
</a>
</td>
</tr>
</table>
</td>
</tr>
</table>
<!--[if mso | IE]>
</td>
<td>
<![endif]-->
<table align="center" border="0" cellpadding="0" cellspacing="0" role="presentation"
style="float:none;display:inline-table;">
<tr>
<td style="padding:0 8px;">
<table border="0" cellpadding="0" cellspacing="0" role="presentation"
style="border-radius:3px;width:24px;">
<tr>
<td style="font-size:0;height:24px;vertical-align:middle;width:24px;">
<a href="https://twitter.com/penpotapp" target="_blank">
<img height="24" src="{{ public-uri }}/images/email/logo-twitter.png"
style="border-radius:3px;display:block;" width="24" />
</a>
</td>
</tr>
</table>
</td>
</tr>
</table>
<!--[if mso | IE]>
</td>
<td>
<![endif]-->
<table align="center" border="0" cellpadding="0" cellspacing="0" role="presentation"
style="float:none;display:inline-table;">
<tr>
<td style="padding:0 8px;">
<table border="0" cellpadding="0" cellspacing="0" role="presentation"
style="border-radius:3px;width:24px;">
<tr>
<td style="font-size:0;height:24px;vertical-align:middle;width:24px;">
<a href="https://github.com/penpot/" target="_blank">
<img height="24" src="{{ public-uri }}/images/email/logo-github.png"
style="border-radius:3px;display:block;" width="24" />
</a>
</td>
</tr>
</table>
</td>
</tr>
</table>
<!--[if mso | IE]>
</td>
<td>
<![endif]-->
<table align="center" border="0" cellpadding="0" cellspacing="0" role="presentation"
style="float:none;display:inline-table;">
<tr>
<td style="padding:0 8px;">
<table border="0" cellpadding="0" cellspacing="0" role="presentation"
style="border-radius:3px;width:24px;">
<tr>
<td style="font-size:0;height:24px;vertical-align:middle;width:24px;">
<a href="https://www.instagram.com/penpot.app/" target="_blank">
<img height="24" src="{{ public-uri }}/images/email/logo-instagram.png"
style="border-radius:3px;display:block;" width="24" />
</a>
</td>
</tr>
</table>
</td>
</tr>
</table>
<!--[if mso | IE]>
</td>
<td>
<![endif]-->
<table align="center" border="0" cellpadding="0" cellspacing="0" role="presentation"
style="float:none;display:inline-table;">
<tr>
<td style="padding:0 8px;">
<table border="0" cellpadding="0" cellspacing="0" role="presentation"
style="border-radius:3px;width:24px;">
<tr>
<td style="font-size:0;height:24px;vertical-align:middle;width:24px;">
<a href="https://tree.taiga.io/project/penpot" target="_blank">
<img height="24" src="{{ public-uri }}/images/email/logo-taiga.png"
style="border-radius:3px;display:block;" width="24" />
</a>
</td>
</tr>
</table>
</td>
</tr>
</table>
<!--[if mso | IE]>
</td>
</tr>
</table>
<![endif]-->
</td>
</tr>
</table>
</div>
<!--[if mso | IE]>
</td>
</tr>
</table>
<![endif]-->
</td>
</tr>
</tbody>
</table>
</div>
<!--[if mso | IE]>
</td>
</tr>
</table>
<table
align="center" border="0" cellpadding="0" cellspacing="0" class="" style="width:600px;" width="600"
>
<tr>
<td style="line-height:0px;font-size:0px;mso-line-height-rule:exactly;">
<![endif]-->
<div style="margin:0px auto;max-width:600px;">
<table align="center" border="0" cellpadding="0" cellspacing="0" role="presentation" style="width:100%;">
<tbody>
<tr>
<td style="direction:ltr;font-size:0px;padding:0 0 24px 0;text-align:center;">
<!--[if mso | IE]>
<table role="presentation" border="0" cellpadding="0" cellspacing="0">
<tr>
<td
class="" style="vertical-align:top;width:600px;"
>
<![endif]-->
<div class="mj-column-per-100 mj-outlook-group-fix"
style="font-size:0px;text-align:left;direction:ltr;display:inline-block;vertical-align:top;width:100%;">
<table border="0" cellpadding="0" cellspacing="0" role="presentation" style="vertical-align:top;"
width="100%">
<tr>
<td align="center" style="font-size:0px;padding:10px 25px;word-break:break-word;">
<div
style="font-family:Source Sans Pro, sans-serif;font-size:14px;line-height:150%;text-align:center;color:#64666A;">
Penpot | Made with &lt;3 and Open Source</div>
</td>
</tr>
</table>
</div>
<!--[if mso | IE]>
</td>
</tr>
</table>
<![endif]-->
</td>
</tr>
</tbody>
</table>
</div>
<!--[if mso | IE]>
</td>
</tr>
</table>
<![endif]-->
</div>
</body>
</html>

View File

@@ -0,0 +1 @@
Request Access to “{{file-name|abbreviate:25}}”

View File

@@ -0,0 +1,30 @@
Hello!
Hello!
{{requested-by|abbreviate:25}} ({{requested-by-email}}) has requested access to the file named “{{file-name|abbreviate:25}}”.
Please note that the file is currently in Your Penpot 's team, so direct access cannot be granted. However, you have two options to provide the requested access:
- Move the File to Another Team:
You can move the file to another team and then give access to that team, inviting {{requested-by|abbreviate:25}}.
- Send a View-Only Link:
Alternatively, you can create and share a view-only link to the file. This will allow {{requested-by|abbreviate:25}} to view the content without making any changes.
Click the link below to generate and send the link:
{{ public-uri }}/#/view/{{file-id}}?page-id={{page-id}}&section=interactions&index=0&share=true
If you do not wish to grant access at this time, you can simply disregard this email.
Thank you
The Penpot team.

View File

@@ -0,0 +1,568 @@
<!doctype html>
<html xmlns="http://www.w3.org/1999/xhtml" xmlns:v="urn:schemas-microsoft-com:vml"
xmlns:o="urn:schemas-microsoft-com:office:office">
<head>
<title>
</title>
<!--[if !mso]><!-- -->
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<!--<![endif]-->
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<style type="text/css">
#outlook a {
padding: 0;
}
body {
margin: 0;
padding: 0;
-webkit-text-size-adjust: 100%;
-ms-text-size-adjust: 100%;
}
table,
td {
border-collapse: collapse;
mso-table-lspace: 0pt;
mso-table-rspace: 0pt;
}
img {
border: 0;
height: auto;
line-height: 100%;
outline: none;
text-decoration: none;
-ms-interpolation-mode: bicubic;
}
p {
display: block;
margin: 13px 0;
}
</style>
<!--[if mso]>
<xml>
<o:OfficeDocumentSettings>
<o:AllowPNG/>
<o:PixelsPerInch>96</o:PixelsPerInch>
</o:OfficeDocumentSettings>
</xml>
<![endif]-->
<!--[if lte mso 11]>
<style type="text/css">
.mj-outlook-group-fix { width:100% !important; }
</style>
<![endif]-->
<!--[if !mso]><!-->
<link href="https://fonts.googleapis.com/css?family=Source%20Sans%20Pro" rel="stylesheet" type="text/css">
<style type="text/css">
@import url(https://fonts.googleapis.com/css?family=Source%20Sans%20Pro);
</style>
<!--<![endif]-->
<style type="text/css">
@media only screen and (min-width:480px) {
.mj-column-per-100 {
width: 100% !important;
max-width: 100%;
}
.mj-column-px-425 {
width: 425px !important;
max-width: 425px;
}
}
</style>
<style type="text/css">
@media only screen and (max-width:480px) {
table.mj-full-width-mobile {
width: 100% !important;
}
td.mj-full-width-mobile {
width: auto !important;
}
}
</style>
</head>
<body style="background-color:#E5E5E5;">
<div style="background-color:#E5E5E5;">
<!--[if mso | IE]>
<table
align="center" border="0" cellpadding="0" cellspacing="0" class="" style="width:600px;" width="600"
>
<tr>
<td style="line-height:0px;font-size:0px;mso-line-height-rule:exactly;">
<![endif]-->
<div style="margin:0px auto;max-width:600px;">
<table align="center" border="0" cellpadding="0" cellspacing="0" role="presentation" style="width:100%;">
<tbody>
<tr>
<td style="direction:ltr;font-size:0px;padding:0;text-align:center;">
<!--[if mso | IE]>
<table role="presentation" border="0" cellpadding="0" cellspacing="0">
<tr>
<td
class="" style="vertical-align:top;width:600px;"
>
<![endif]-->
<div class="mj-column-per-100 mj-outlook-group-fix"
style="font-size:0px;text-align:left;direction:ltr;display:inline-block;vertical-align:top;width:100%;">
<table border="0" cellpadding="0" cellspacing="0" role="presentation" style="vertical-align:top;"
width="100%">
<tr>
<td align="left" style="font-size:0px;padding:16px;word-break:break-word;">
<table border="0" cellpadding="0" cellspacing="0" role="presentation"
style="border-collapse:collapse;border-spacing:0px;">
<tbody>
<tr>
<td style="width:97px;">
<img height="32" src="{{ public-uri }}/images/email/uxbox-title.png"
style="border:0;display:block;outline:none;text-decoration:none;height:32px;width:100%;font-size:13px;"
width="97" />
</td>
</tr>
</tbody>
</table>
</td>
</tr>
</table>
</div>
<!--[if mso | IE]>
</td>
</tr>
</table>
<![endif]-->
</td>
</tr>
</tbody>
</table>
</div>
<!--[if mso | IE]>
</td>
</tr>
</table>
<table
align="center" border="0" cellpadding="0" cellspacing="0" class="" style="width:600px;" width="600"
>
<tr>
<td style="line-height:0px;font-size:0px;mso-line-height-rule:exactly;">
<![endif]-->
<div style="background:#FFFFFF;background-color:#FFFFFF;margin:0px auto;max-width:600px;">
<table align="center" border="0" cellpadding="0" cellspacing="0" role="presentation"
style="background:#FFFFFF;background-color:#FFFFFF;width:100%;">
<tbody>
<tr>
<td style="direction:ltr;font-size:0px;padding:20px 0;text-align:center;">
<!--[if mso | IE]>
<table role="presentation" border="0" cellpadding="0" cellspacing="0">
<tr>
<td
class="" style="vertical-align:top;width:600px;"
>
<![endif]-->
<div class="mj-column-per-100 mj-outlook-group-fix"
style="font-size:0px;text-align:left;direction:ltr;display:inline-block;vertical-align:top;width:100%;">
<table border="0" cellpadding="0" cellspacing="0" role="presentation" style="vertical-align:top;"
width="100%">
<tr>
<td align="left" style="font-size:0px;padding:10px 25px;word-break:break-word;">
<div
style="font-family:Source Sans Pro, sans-serif;font-size:24px;font-weight:600;line-height:150%;text-align:left;color:#000000;">
Hello!</div>
</td>
</tr>
<tr>
<td align="left" style="font-size:0px;padding:10px 25px;word-break:break-word;">
<div
style="font-family:Source Sans Pro, sans-serif;font-size:16px;line-height:150%;text-align:left;color:#000000;">
<p>
{{requested-by|abbreviate:25}} ({{requested-by-email}}) has requested access to the file named
“{{file-name|abbreviate:25}}”.
</p>
<p>
To provide this access, you have the following options:
</p>
<ul>
<li>
<p>Give Access to the “{{team-name|abbreviate:25}}” Team:</p>
<p>This will automatically include {{requested-by|abbreviate:25}} in the team, so the user
can see all the projects and files in it.</p>
<p>Click the button below to provide team access:</p>
</li>
</ul>
</p>
</div>
</td>
</tr>
<tr>
<td align="center" vertical-align="middle"
style="font-size:0px;padding:10px 25px;word-break:break-word;">
<table border="0" cellpadding="0" cellspacing="0" role="presentation"
style="border-collapse:separate;line-height:100%">
<tr>
<td align="center" bgcolor="#31EFB8" role="presentation"
style="border:none;border-radius:3px;cursor:auto;mso-padding-alt:10px 25px;background:#31EFB8;"
valign="middle">
<a href="{{ public-uri }}/#/dashboard/team/{{team-id}}/members?invite-email={{requested-by-email|urlescape }}"
style="display:inline-block;background:#31EFB8;color:#1F1F1F;font-family:Source Sans Pro, sans-serif;font-size:16px;font-weight:normal;line-height:120%;margin:0;text-decoration:none;text-transform:none;padding:10px 25px;mso-padding-alt:0px;border-radius:3px;"
target="_blank"> Give access to “{{team-name|abbreviate:25}}” Team </a>
</td>
</tr>
</table>
</td>
</tr>
<tr>
<td align="left" style="font-size:0px;padding:10px 25px;word-break:break-word;">
<div
style="font-family:Source Sans Pro, sans-serif;font-size:16px;line-height:150%;text-align:left;color:#000000;">
<ul>
<li>
<p>Send a View-Only Link:</p>
<p>Alternatively, you can create and share a view-only link to the file. This will allow
{{requested-by|abbreviate:25}} to view the content without making any changes.</p>
<p>Click the button below to generate and send the link:</p>
</li>
</ul>
</p>
</div>
</td>
</tr>
<tr>
<td align="center" vertical-align="middle"
style="font-size:0px;padding:10px 25px;word-break:break-word;">
<table border="0" cellpadding="0" cellspacing="0" role="presentation"
style="border-collapse:separate;line-height:100%">
<tr>
<td align="center" bgcolor="#31EFB8" role="presentation"
style="border:none;border-radius:3px;cursor:auto;mso-padding-alt:10px 25px;background:#31EFB8;"
valign="middle">
<a href="{{ public-uri }}/#/view/{{file-id}}?page-id={{page-id}}&section=interactions&index=0&share=true"
style="display:inline-block;background:#31EFB8;color:#1F1F1F;font-family:Source Sans Pro, sans-serif;font-size:16px;font-weight:normal;line-height:120%;margin:0;text-decoration:none;text-transform:none;padding:10px 25px;mso-padding-alt:0px;border-radius:3px;"
target="_blank"> Send a View-Only link </a>
</td>
</tr>
</table>
</td>
</tr>
<tr>
<td align="left" style="font-size:0px;padding:10px 25px;word-break:break-word;">
<div
style="font-family:Source Sans Pro, sans-serif;font-size:16px;line-height:150%;text-align:left;color:#000000;">
<p>If you do not wish to grant access at this time, you can simply disregard this email.</p>
<p>Thank you</p>
</div>
</td>
</tr>
<tr>
<td align="left" style="font-size:0px;padding:10px 25px;word-break:break-word;">
<div
style="font-family:Source Sans Pro, sans-serif;font-size:16px;line-height:150%;text-align:left;color:#000000;">
The Penpot team.</div>
</td>
</tr>
</table>
</div>
<!--[if mso | IE]>
</td>
</tr>
</table>
<![endif]-->
</td>
</tr>
</tbody>
</table>
</div>
<!--[if mso | IE]>
</td>
</tr>
</table>
<table
align="center" border="0" cellpadding="0" cellspacing="0" class="" style="width:600px;" width="600"
>
<tr>
<td style="line-height:0px;font-size:0px;mso-line-height-rule:exactly;">
<![endif]-->
<div style="margin:0px auto;max-width:600px;">
<table align="center" border="0" cellpadding="0" cellspacing="0" role="presentation" style="width:100%;">
<tbody>
<tr>
<td style="direction:ltr;font-size:0px;padding:24px 0 0 0;text-align:center;">
<!--[if mso | IE]>
<table role="presentation" border="0" cellpadding="0" cellspacing="0">
<tr>
<td
class="" style="vertical-align:top;width:425px;"
>
<![endif]-->
<div class="mj-column-px-425 mj-outlook-group-fix"
style="font-size:0px;text-align:left;direction:ltr;display:inline-block;vertical-align:top;width:100%;">
<table border="0" cellpadding="0" cellspacing="0" role="presentation" style="vertical-align:top;"
width="100%">
<tr>
<td align="center" style="font-size:0px;padding:10px 25px;word-break:break-word;">
<div
style="font-family:Source Sans Pro, sans-serif;font-size:14px;line-height:150%;text-align:center;color:#64666A;">
Penpot is the first Open Source design and prototyping platform meant for cross-domain teams.
</div>
</td>
</tr>
</table>
</div>
<!--[if mso | IE]>
</td>
</tr>
</table>
<![endif]-->
</td>
</tr>
</tbody>
</table>
</div>
<!--[if mso | IE]>
</td>
</tr>
</table>
<table
align="center" border="0" cellpadding="0" cellspacing="0" class="" style="width:600px;" width="600"
>
<tr>
<td style="line-height:0px;font-size:0px;mso-line-height-rule:exactly;">
<![endif]-->
<div style="margin:0px auto;max-width:600px;">
<table align="center" border="0" cellpadding="0" cellspacing="0" role="presentation" style="width:100%;">
<tbody>
<tr>
<td style="direction:ltr;font-size:0px;padding:0;text-align:center;">
<!--[if mso | IE]>
<table role="presentation" border="0" cellpadding="0" cellspacing="0">
<tr>
<td
class="" style="vertical-align:top;width:600px;"
>
<![endif]-->
<div class="mj-column-per-100 mj-outlook-group-fix"
style="font-size:0px;text-align:left;direction:ltr;display:inline-block;vertical-align:top;width:100%;">
<table border="0" cellpadding="0" cellspacing="0" role="presentation" style="vertical-align:top;"
width="100%">
<tr>
<td align="center" style="font-size:0px;padding:10px 25px;word-break:break-word;">
<!--[if mso | IE]>
<table
align="center" border="0" cellpadding="0" cellspacing="0" role="presentation"
>
<tr>
<td>
<![endif]-->
<table align="center" border="0" cellpadding="0" cellspacing="0" role="presentation"
style="float:none;display:inline-table;">
<tr>
<td style="padding:0 8px;">
<table border="0" cellpadding="0" cellspacing="0" role="presentation"
style="border-radius:3px;width:24px;">
<tr>
<td style="font-size:0;height:24px;vertical-align:middle;width:24px;">
<a href="https://penpot.app/" target="_blank">
<img height="24" src="{{ public-uri }}/images/email/logo-uxbox.png"
style="border-radius:3px;display:block;" width="24" />
</a>
</td>
</tr>
</table>
</td>
</tr>
</table>
<!--[if mso | IE]>
</td>
<td>
<![endif]-->
<table align="center" border="0" cellpadding="0" cellspacing="0" role="presentation"
style="float:none;display:inline-table;">
<tr>
<td style="padding:0 8px;">
<table border="0" cellpadding="0" cellspacing="0" role="presentation"
style="border-radius:3px;width:24px;">
<tr>
<td style="font-size:0;height:24px;vertical-align:middle;width:24px;">
<a href="https://twitter.com/penpotapp" target="_blank">
<img height="24" src="{{ public-uri }}/images/email/logo-twitter.png"
style="border-radius:3px;display:block;" width="24" />
</a>
</td>
</tr>
</table>
</td>
</tr>
</table>
<!--[if mso | IE]>
</td>
<td>
<![endif]-->
<table align="center" border="0" cellpadding="0" cellspacing="0" role="presentation"
style="float:none;display:inline-table;">
<tr>
<td style="padding:0 8px;">
<table border="0" cellpadding="0" cellspacing="0" role="presentation"
style="border-radius:3px;width:24px;">
<tr>
<td style="font-size:0;height:24px;vertical-align:middle;width:24px;">
<a href="https://github.com/penpot/" target="_blank">
<img height="24" src="{{ public-uri }}/images/email/logo-github.png"
style="border-radius:3px;display:block;" width="24" />
</a>
</td>
</tr>
</table>
</td>
</tr>
</table>
<!--[if mso | IE]>
</td>
<td>
<![endif]-->
<table align="center" border="0" cellpadding="0" cellspacing="0" role="presentation"
style="float:none;display:inline-table;">
<tr>
<td style="padding:0 8px;">
<table border="0" cellpadding="0" cellspacing="0" role="presentation"
style="border-radius:3px;width:24px;">
<tr>
<td style="font-size:0;height:24px;vertical-align:middle;width:24px;">
<a href="https://www.instagram.com/penpot.app/" target="_blank">
<img height="24" src="{{ public-uri }}/images/email/logo-instagram.png"
style="border-radius:3px;display:block;" width="24" />
</a>
</td>
</tr>
</table>
</td>
</tr>
</table>
<!--[if mso | IE]>
</td>
<td>
<![endif]-->
<table align="center" border="0" cellpadding="0" cellspacing="0" role="presentation"
style="float:none;display:inline-table;">
<tr>
<td style="padding:0 8px;">
<table border="0" cellpadding="0" cellspacing="0" role="presentation"
style="border-radius:3px;width:24px;">
<tr>
<td style="font-size:0;height:24px;vertical-align:middle;width:24px;">
<a href="https://tree.taiga.io/project/penpot" target="_blank">
<img height="24" src="{{ public-uri }}/images/email/logo-taiga.png"
style="border-radius:3px;display:block;" width="24" />
</a>
</td>
</tr>
</table>
</td>
</tr>
</table>
<!--[if mso | IE]>
</td>
</tr>
</table>
<![endif]-->
</td>
</tr>
</table>
</div>
<!--[if mso | IE]>
</td>
</tr>
</table>
<![endif]-->
</td>
</tr>
</tbody>
</table>
</div>
<!--[if mso | IE]>
</td>
</tr>
</table>
<table
align="center" border="0" cellpadding="0" cellspacing="0" class="" style="width:600px;" width="600"
>
<tr>
<td style="line-height:0px;font-size:0px;mso-line-height-rule:exactly;">
<![endif]-->
<div style="margin:0px auto;max-width:600px;">
<table align="center" border="0" cellpadding="0" cellspacing="0" role="presentation" style="width:100%;">
<tbody>
<tr>
<td style="direction:ltr;font-size:0px;padding:0 0 24px 0;text-align:center;">
<!--[if mso | IE]>
<table role="presentation" border="0" cellpadding="0" cellspacing="0">
<tr>
<td
class="" style="vertical-align:top;width:600px;"
>
<![endif]-->
<div class="mj-column-per-100 mj-outlook-group-fix"
style="font-size:0px;text-align:left;direction:ltr;display:inline-block;vertical-align:top;width:100%;">
<table border="0" cellpadding="0" cellspacing="0" role="presentation" style="vertical-align:top;"
width="100%">
<tr>
<td align="center" style="font-size:0px;padding:10px 25px;word-break:break-word;">
<div
style="font-family:Source Sans Pro, sans-serif;font-size:14px;line-height:150%;text-align:center;color:#64666A;">
Penpot | Made with &lt;3 and Open Source</div>
</td>
</tr>
</table>
</div>
<!--[if mso | IE]>
</td>
</tr>
</table>
<![endif]-->
</td>
</tr>
</tbody>
</table>
</div>
<!--[if mso | IE]>
</td>
</tr>
</table>
<![endif]-->
</div>
</body>
</html>

View File

@@ -0,0 +1 @@
Request Access to “{{file-name|abbreviate:25}}”

View File

@@ -0,0 +1,34 @@
Hello!
Hello!
{{requested-by|abbreviate:25}} ({{requested-by-email}}) has requested access to the file named “{{file-name|abbreviate:25}}”.
To provide this access, you have the following options:
- Give Access to the “{{team-name|abbreviate:25}}” Team:
This will automatically include {{requested-by|abbreviate:25}} in the team, so the user can see all the projects and files in it.
Click the link below to provide team access:
{{ public-uri }}/#/dashboard/team/{{team-id}}/members?invite-email={{requested-by-email|urlescape}}
- Send a View-Only Link:
Alternatively, you can create and share a view-only link to the file. This will allow {{requested-by|abbreviate:25}} to view the content without making any changes.
Click the link below to generate and send the link:
{{ public-uri }}/#/view/{{file-id}}?page-id={{page-id}}&section=interactions&index=0&share=true
If you do not wish to grant access at this time, you can simply disregard this email.
Thank you
The Penpot team.

View File

@@ -0,0 +1,526 @@
<!doctype html>
<html xmlns="http://www.w3.org/1999/xhtml" xmlns:v="urn:schemas-microsoft-com:vml"
xmlns:o="urn:schemas-microsoft-com:office:office">
<head>
<title>
</title>
<!--[if !mso]><!-- -->
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<!--<![endif]-->
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<style type="text/css">
#outlook a {
padding: 0;
}
body {
margin: 0;
padding: 0;
-webkit-text-size-adjust: 100%;
-ms-text-size-adjust: 100%;
}
table,
td {
border-collapse: collapse;
mso-table-lspace: 0pt;
mso-table-rspace: 0pt;
}
img {
border: 0;
height: auto;
line-height: 100%;
outline: none;
text-decoration: none;
-ms-interpolation-mode: bicubic;
}
p {
display: block;
margin: 13px 0;
}
</style>
<!--[if mso]>
<xml>
<o:OfficeDocumentSettings>
<o:AllowPNG/>
<o:PixelsPerInch>96</o:PixelsPerInch>
</o:OfficeDocumentSettings>
</xml>
<![endif]-->
<!--[if lte mso 11]>
<style type="text/css">
.mj-outlook-group-fix { width:100% !important; }
</style>
<![endif]-->
<!--[if !mso]><!-->
<link href="https://fonts.googleapis.com/css?family=Source%20Sans%20Pro" rel="stylesheet" type="text/css">
<style type="text/css">
@import url(https://fonts.googleapis.com/css?family=Source%20Sans%20Pro);
</style>
<!--<![endif]-->
<style type="text/css">
@media only screen and (min-width:480px) {
.mj-column-per-100 {
width: 100% !important;
max-width: 100%;
}
.mj-column-px-425 {
width: 425px !important;
max-width: 425px;
}
}
</style>
<style type="text/css">
@media only screen and (max-width:480px) {
table.mj-full-width-mobile {
width: 100% !important;
}
td.mj-full-width-mobile {
width: auto !important;
}
}
</style>
</head>
<body style="background-color:#E5E5E5;">
<div style="background-color:#E5E5E5;">
<!--[if mso | IE]>
<table
align="center" border="0" cellpadding="0" cellspacing="0" class="" style="width:600px;" width="600"
>
<tr>
<td style="line-height:0px;font-size:0px;mso-line-height-rule:exactly;">
<![endif]-->
<div style="margin:0px auto;max-width:600px;">
<table align="center" border="0" cellpadding="0" cellspacing="0" role="presentation" style="width:100%;">
<tbody>
<tr>
<td style="direction:ltr;font-size:0px;padding:0;text-align:center;">
<!--[if mso | IE]>
<table role="presentation" border="0" cellpadding="0" cellspacing="0">
<tr>
<td
class="" style="vertical-align:top;width:600px;"
>
<![endif]-->
<div class="mj-column-per-100 mj-outlook-group-fix"
style="font-size:0px;text-align:left;direction:ltr;display:inline-block;vertical-align:top;width:100%;">
<table border="0" cellpadding="0" cellspacing="0" role="presentation" style="vertical-align:top;"
width="100%">
<tr>
<td align="left" style="font-size:0px;padding:16px;word-break:break-word;">
<table border="0" cellpadding="0" cellspacing="0" role="presentation"
style="border-collapse:collapse;border-spacing:0px;">
<tbody>
<tr>
<td style="width:97px;">
<img height="32" src="{{ public-uri }}/images/email/uxbox-title.png"
style="border:0;display:block;outline:none;text-decoration:none;height:32px;width:100%;font-size:13px;"
width="97" />
</td>
</tr>
</tbody>
</table>
</td>
</tr>
</table>
</div>
<!--[if mso | IE]>
</td>
</tr>
</table>
<![endif]-->
</td>
</tr>
</tbody>
</table>
</div>
<!--[if mso | IE]>
</td>
</tr>
</table>
<table
align="center" border="0" cellpadding="0" cellspacing="0" class="" style="width:600px;" width="600"
>
<tr>
<td style="line-height:0px;font-size:0px;mso-line-height-rule:exactly;">
<![endif]-->
<div style="background:#FFFFFF;background-color:#FFFFFF;margin:0px auto;max-width:600px;">
<table align="center" border="0" cellpadding="0" cellspacing="0" role="presentation"
style="background:#FFFFFF;background-color:#FFFFFF;width:100%;">
<tbody>
<tr>
<td style="direction:ltr;font-size:0px;padding:20px 0;text-align:center;">
<!--[if mso | IE]>
<table role="presentation" border="0" cellpadding="0" cellspacing="0">
<tr>
<td
class="" style="vertical-align:top;width:600px;"
>
<![endif]-->
<div class="mj-column-per-100 mj-outlook-group-fix"
style="font-size:0px;text-align:left;direction:ltr;display:inline-block;vertical-align:top;width:100%;">
<table border="0" cellpadding="0" cellspacing="0" role="presentation" style="vertical-align:top;"
width="100%">
<tr>
<td align="left" style="font-size:0px;padding:10px 25px;word-break:break-word;">
<div
style="font-family:Source Sans Pro, sans-serif;font-size:24px;font-weight:600;line-height:150%;text-align:left;color:#000000;">
Hello!</div>
</td>
</tr>
<tr>
<td align="left" style="font-size:0px;padding:10px 25px;word-break:break-word;">
<div
style="font-family:Source Sans Pro, sans-serif;font-size:16px;line-height:150%;text-align:left;color:#000000;">
<p>
{{requested-by|abbreviate:25}} ({{requested-by-email}}) wants to have access to the
“{{team-name|abbreviate:25}}” Team.
</p>
<p>
To provide access, please click the button below:
</p>
</div>
</td>
</tr>
<tr>
<td align="center" vertical-align="middle"
style="font-size:0px;padding:10px 25px;word-break:break-word;">
<table border="0" cellpadding="0" cellspacing="0" role="presentation"
style="border-collapse:separate;line-height:100%;">
<tr>
<td align="center" bgcolor="#31EFB8" role="presentation"
style="border:none;border-radius:3px;cursor:auto;mso-padding-alt:10px 25px;background:#31EFB8;"
valign="middle">
<a href="{{ public-uri }}/#/dashboard/team/{{team-id}}/members?invite-email={{requested-by-email|urlescape}}"
style="display:inline-block;background:#31EFB8;color:#1F1F1F;font-family:Source Sans Pro, sans-serif;font-size:16px;font-weight:normal;line-height:120%;margin:0;text-decoration:none;text-transform:none;padding:10px 25px;mso-padding-alt:0px;border-radius:3px;"
target="_blank"> Give access to “{{team-name|abbreviate:25}}” </a>
</td>
</tr>
</table>
</td>
</tr>
<tr>
<td align="left" style="font-size:0px;padding:10px 25px;word-break:break-word;">
<div
style="font-family:Source Sans Pro, sans-serif;font-size:16px;line-height:150%;text-align:left;color:#000000;">
<p>If you do not wish to grant access at this time, you can simply disregard this email.</p>
<p>Thank you</p>
</div>
</td>
</tr>
<tr>
<td align="left" style="font-size:0px;padding:10px 25px;word-break:break-word;">
<div
style="font-family:Source Sans Pro, sans-serif;font-size:16px;line-height:150%;text-align:left;color:#000000;">
The Penpot team.</div>
</td>
</tr>
</table>
</div>
<!--[if mso | IE]>
</td>
</tr>
</table>
<![endif]-->
</td>
</tr>
</tbody>
</table>
</div>
<!--[if mso | IE]>
</td>
</tr>
</table>
<table
align="center" border="0" cellpadding="0" cellspacing="0" class="" style="width:600px;" width="600"
>
<tr>
<td style="line-height:0px;font-size:0px;mso-line-height-rule:exactly;">
<![endif]-->
<div style="margin:0px auto;max-width:600px;">
<table align="center" border="0" cellpadding="0" cellspacing="0" role="presentation" style="width:100%;">
<tbody>
<tr>
<td style="direction:ltr;font-size:0px;padding:24px 0 0 0;text-align:center;">
<!--[if mso | IE]>
<table role="presentation" border="0" cellpadding="0" cellspacing="0">
<tr>
<td
class="" style="vertical-align:top;width:425px;"
>
<![endif]-->
<div class="mj-column-px-425 mj-outlook-group-fix"
style="font-size:0px;text-align:left;direction:ltr;display:inline-block;vertical-align:top;width:100%;">
<table border="0" cellpadding="0" cellspacing="0" role="presentation" style="vertical-align:top;"
width="100%">
<tr>
<td align="center" style="font-size:0px;padding:10px 25px;word-break:break-word;">
<div
style="font-family:Source Sans Pro, sans-serif;font-size:14px;line-height:150%;text-align:center;color:#64666A;">
Penpot is the first Open Source design and prototyping platform meant for cross-domain teams.
</div>
</td>
</tr>
</table>
</div>
<!--[if mso | IE]>
</td>
</tr>
</table>
<![endif]-->
</td>
</tr>
</tbody>
</table>
</div>
<!--[if mso | IE]>
</td>
</tr>
</table>
<table
align="center" border="0" cellpadding="0" cellspacing="0" class="" style="width:600px;" width="600"
>
<tr>
<td style="line-height:0px;font-size:0px;mso-line-height-rule:exactly;">
<![endif]-->
<div style="margin:0px auto;max-width:600px;">
<table align="center" border="0" cellpadding="0" cellspacing="0" role="presentation" style="width:100%;">
<tbody>
<tr>
<td style="direction:ltr;font-size:0px;padding:0;text-align:center;">
<!--[if mso | IE]>
<table role="presentation" border="0" cellpadding="0" cellspacing="0">
<tr>
<td
class="" style="vertical-align:top;width:600px;"
>
<![endif]-->
<div class="mj-column-per-100 mj-outlook-group-fix"
style="font-size:0px;text-align:left;direction:ltr;display:inline-block;vertical-align:top;width:100%;">
<table border="0" cellpadding="0" cellspacing="0" role="presentation" style="vertical-align:top;"
width="100%">
<tr>
<td align="center" style="font-size:0px;padding:10px 25px;word-break:break-word;">
<!--[if mso | IE]>
<table
align="center" border="0" cellpadding="0" cellspacing="0" role="presentation"
>
<tr>
<td>
<![endif]-->
<table align="center" border="0" cellpadding="0" cellspacing="0" role="presentation"
style="float:none;display:inline-table;">
<tr>
<td style="padding:0 8px;">
<table border="0" cellpadding="0" cellspacing="0" role="presentation"
style="border-radius:3px;width:24px;">
<tr>
<td style="font-size:0;height:24px;vertical-align:middle;width:24px;">
<a href="https://penpot.app/" target="_blank">
<img height="24" src="{{ public-uri }}/images/email/logo-uxbox.png"
style="border-radius:3px;display:block;" width="24" />
</a>
</td>
</tr>
</table>
</td>
</tr>
</table>
<!--[if mso | IE]>
</td>
<td>
<![endif]-->
<table align="center" border="0" cellpadding="0" cellspacing="0" role="presentation"
style="float:none;display:inline-table;">
<tr>
<td style="padding:0 8px;">
<table border="0" cellpadding="0" cellspacing="0" role="presentation"
style="border-radius:3px;width:24px;">
<tr>
<td style="font-size:0;height:24px;vertical-align:middle;width:24px;">
<a href="https://twitter.com/penpotapp" target="_blank">
<img height="24" src="{{ public-uri }}/images/email/logo-twitter.png"
style="border-radius:3px;display:block;" width="24" />
</a>
</td>
</tr>
</table>
</td>
</tr>
</table>
<!--[if mso | IE]>
</td>
<td>
<![endif]-->
<table align="center" border="0" cellpadding="0" cellspacing="0" role="presentation"
style="float:none;display:inline-table;">
<tr>
<td style="padding:0 8px;">
<table border="0" cellpadding="0" cellspacing="0" role="presentation"
style="border-radius:3px;width:24px;">
<tr>
<td style="font-size:0;height:24px;vertical-align:middle;width:24px;">
<a href="https://github.com/penpot/" target="_blank">
<img height="24" src="{{ public-uri }}/images/email/logo-github.png"
style="border-radius:3px;display:block;" width="24" />
</a>
</td>
</tr>
</table>
</td>
</tr>
</table>
<!--[if mso | IE]>
</td>
<td>
<![endif]-->
<table align="center" border="0" cellpadding="0" cellspacing="0" role="presentation"
style="float:none;display:inline-table;">
<tr>
<td style="padding:0 8px;">
<table border="0" cellpadding="0" cellspacing="0" role="presentation"
style="border-radius:3px;width:24px;">
<tr>
<td style="font-size:0;height:24px;vertical-align:middle;width:24px;">
<a href="https://www.instagram.com/penpot.app/" target="_blank">
<img height="24" src="{{ public-uri }}/images/email/logo-instagram.png"
style="border-radius:3px;display:block;" width="24" />
</a>
</td>
</tr>
</table>
</td>
</tr>
</table>
<!--[if mso | IE]>
</td>
<td>
<![endif]-->
<table align="center" border="0" cellpadding="0" cellspacing="0" role="presentation"
style="float:none;display:inline-table;">
<tr>
<td style="padding:0 8px;">
<table border="0" cellpadding="0" cellspacing="0" role="presentation"
style="border-radius:3px;width:24px;">
<tr>
<td style="font-size:0;height:24px;vertical-align:middle;width:24px;">
<a href="https://tree.taiga.io/project/penpot" target="_blank">
<img height="24" src="{{ public-uri }}/images/email/logo-taiga.png"
style="border-radius:3px;display:block;" width="24" />
</a>
</td>
</tr>
</table>
</td>
</tr>
</table>
<!--[if mso | IE]>
</td>
</tr>
</table>
<![endif]-->
</td>
</tr>
</table>
</div>
<!--[if mso | IE]>
</td>
</tr>
</table>
<![endif]-->
</td>
</tr>
</tbody>
</table>
</div>
<!--[if mso | IE]>
</td>
</tr>
</table>
<table
align="center" border="0" cellpadding="0" cellspacing="0" class="" style="width:600px;" width="600"
>
<tr>
<td style="line-height:0px;font-size:0px;mso-line-height-rule:exactly;">
<![endif]-->
<div style="margin:0px auto;max-width:600px;">
<table align="center" border="0" cellpadding="0" cellspacing="0" role="presentation" style="width:100%;">
<tbody>
<tr>
<td style="direction:ltr;font-size:0px;padding:0 0 24px 0;text-align:center;">
<!--[if mso | IE]>
<table role="presentation" border="0" cellpadding="0" cellspacing="0">
<tr>
<td
class="" style="vertical-align:top;width:600px;"
>
<![endif]-->
<div class="mj-column-per-100 mj-outlook-group-fix"
style="font-size:0px;text-align:left;direction:ltr;display:inline-block;vertical-align:top;width:100%;">
<table border="0" cellpadding="0" cellspacing="0" role="presentation" style="vertical-align:top;"
width="100%">
<tr>
<td align="center" style="font-size:0px;padding:10px 25px;word-break:break-word;">
<div
style="font-family:Source Sans Pro, sans-serif;font-size:14px;line-height:150%;text-align:center;color:#64666A;">
Penpot | Made with &lt;3 and Open Source</div>
</td>
</tr>
</table>
</div>
<!--[if mso | IE]>
</td>
</tr>
</table>
<![endif]-->
</td>
</tr>
</tbody>
</table>
</div>
<!--[if mso | IE]>
</td>
</tr>
</table>
<![endif]-->
</div>
</body>
</html>

View File

@@ -0,0 +1 @@
Request Access to “{{team-name|abbreviate:25}}”

View File

@@ -0,0 +1,14 @@
Hello!
{{requested-by|abbreviate:25}} ({{requested-by-email}}) wants to have access to the “{{team-name|abbreviate:25}}” Team.
To provide access, please click the link below:
{{ public-uri }}/#/dashboard/team/{{team-id}}/members?invite-email={{requested-by-email|urlescape}}
If you do not wish to grant access at this time, you can simply disregard this email.
Thank you
The Penpot team.

View File

@@ -1,33 +1,42 @@
[{:id "tutorial-for-beginners"
[{:id "wireframing-kit"
:name "Wireframe library"
:file-uri "https://github.com/penpot/penpot-files/raw/main/wireframing-kit.penpot"}
{:id "prototype-examples"
:name "Prototype template"
:file-uri "https://github.com/penpot/penpot-files/raw/main/prototype-examples.penpot"}
{:id "plants-app"
:name "UI mockup example"
:file-uri "https://github.com/penpot/penpot-files/raw/main/Plants-app.penpot"}
{:id "penpot-design-system"
:name "Design system example"
:file-uri "https://github.com/penpot/penpot-files/raw/main/Penpot-Design-system.penpot"}
{:id "tutorial-for-beginners"
:name "Tutorial for beginners"
:file-uri "https://github.com/penpot/penpot-files/raw/binary-files/tutorial-for-beginners.penpot"}
:file-uri "https://github.com/penpot/penpot-files/raw/main/tutorial-for-beginners.penpot"}
{:id "lucide-icons"
:name "Lucide Icons"
:file-uri "https://github.com/penpot/penpot-files/raw/binary-files/Lucide-icons.penpot"}
:file-uri "https://github.com/penpot/penpot-files/raw/main/Lucide-icons.penpot"}
{:id "font-awesome"
:name "Font Awesome"
:file-uri "https://github.com/penpot/penpot-files/raw/binary-files/Font-Awesome.penpot"}
{:id "plants-app"
:name "Plants app"
:file-uri "https://github.com/penpot/penpot-files/raw/binary-files/Plants-app.penpot"}
{:id "wireframing-kit"
:name "Wireframing Kit"
:file-uri "https://github.com/penpot/penpot-files/raw/binary-files/wireframing-kit.penpot"}
:file-uri "https://github.com/penpot/penpot-files/raw/main/FontAwesome.penpot"}
{:id "black-white-mobile-templates"
:name "Black & White Mobile Templates"
:file-uri "https://github.com/penpot/penpot-files/raw/binary-files/Black-White-Mobile-Templates.penpot"}
:file-uri "https://github.com/penpot/penpot-files/raw/main/Black-&-White-Mobile-Templates.penpot"}
{:id "avataaars"
:name "Avataaars"
:file-uri "https://github.com/penpot/penpot-files/raw/binary-files/Avataaars-by-Pablo-Stanley.penpot"}
:file-uri "https://github.com/penpot/penpot-files/raw/main/Avataaars-by-Pablo-Stanley.penpot"}
{:id "ux-notes"
:name "UX Notes"
:file-uri "https://github.com/penpot/penpot-files/raw/binary-files/UX-Notes.penpot"}
:file-uri "https://github.com/penpot/penpot-files/raw/main/UX-Notes.penpot"}
{:id "whiteboarding-kit"
:name "Whiteboarding Kit"
:file-uri "https://github.com/penpot/penpot-files/raw/binary-files/Whiteboarding-mapping-kit.penpot"}
:file-uri "https://github.com/penpot/penpot-files/raw/main/Whiteboarding-mapping-kit.penpot"}
{:id "open-color-scheme"
:name "Open Color Scheme"
:file-uri "https://github.com/penpot/penpot-files/raw/binary-files/Open-Color-Scheme.penpot"}
:file-uri "https://github.com/penpot/penpot-files/raw/main/Open%20Color%20Scheme%20(v1.9.1).penpot"}
{:id "flex-layout-playground"
:name "Flex Layout Playground"
:file-uri "https://github.com/penpot/penpot-files/raw/binary-files/Flex-Layout-Playground.penpot"}]
:file-uri "https://github.com/penpot/penpot-files/raw/main/Flex%20Layout%20Playground.penpot"}
{:id "welcome"
:name "Welcome"
:file-uri "https://github.com/penpot/penpot-files/raw/main/welcome.penpot"}]

View File

@@ -20,12 +20,19 @@
<span>WEBHOOK</span>
</span>
{% endif %}
{% if item.params-schema-js %}
<span class="tag">
<span>SCHEMA</span>
</span>
{% endif %}
{% if item.spec %}
<span class="tag">
<span>SPEC</span>
</span>
{% endif %}
{% if item.sse %}
<span class="tag">
<span>SSE</span>

View File

@@ -24,8 +24,10 @@ export PENPOT_FLAGS="\
enable-rpc-climit \
enable-rpc-rlimit \
enable-soft-rpc-rlimit \
enable-auto-file-snapshot \
enable-webhooks \
enable-access-tokens \
enable-tiered-file-data-storage \
enable-file-validation \
enable-file-schema-validation";
@@ -61,9 +63,10 @@ mc mb penpot-s3/penpot -p -q
export AWS_ACCESS_KEY_ID=penpot-devenv
export AWS_SECRET_ACCESS_KEY=penpot-devenv
export PENPOT_ASSETS_STORAGE_BACKEND=assets-s3
export PENPOT_STORAGE_ASSETS_S3_ENDPOINT=http://minio:9000
export PENPOT_STORAGE_ASSETS_S3_BUCKET=penpot
export PENPOT_OBJECTS_STORAGE_BACKEND=s3
export PENPOT_OBJECTS_STORAGE_S3_ENDPOINT=http://minio:9000
export PENPOT_OBJECTS_STORAGE_S3_BUCKET=penpot
export OPTIONS="
-A:jmx-remote -A:dev \

View File

@@ -17,7 +17,9 @@ export PENPOT_FLAGS="\
disable-secure-session-cookies \
enable-rpc-climit \
enable-smtp \
enable-file-snapshot \
enable-access-tokens \
enable-tiered-file-data-storage \
enable-file-validation \
enable-file-schema-validation";
@@ -55,9 +57,9 @@ mc mb penpot-s3/penpot -p -q
export AWS_ACCESS_KEY_ID=penpot-devenv
export AWS_SECRET_ACCESS_KEY=penpot-devenv
export PENPOT_ASSETS_STORAGE_BACKEND=assets-s3
export PENPOT_STORAGE_ASSETS_S3_ENDPOINT=http://minio:9000
export PENPOT_STORAGE_ASSETS_S3_BUCKET=penpot
export PENPOT_OBJECTS_STORAGE_BACKEND=s3
export PENPOT_OBJECTS_STORAGE_S3_ENDPOINT=http://minio:9000
export PENPOT_OBJECTS_STORAGE_S3_BUCKET=penpot
entrypoint=${1:-app.main};

View File

@@ -6,9 +6,7 @@
(ns app.auth
(:require
[app.config :as cf]
[buddy.hashers :as hashers]
[cuerdas.core :as str]))
[buddy.hashers :as hashers]))
(def default-params
{:alg :argon2id
@@ -27,17 +25,3 @@
(catch Throwable _
{:update false
:valid false})))
(defn email-domain-in-whitelist?
"Returns true if email's domain is in the given whitelist or if
given whitelist is an empty string."
([email]
(let [domains (cf/get :registration-domain-whitelist)]
(email-domain-in-whitelist? domains email)))
([domains email]
(if (or (nil? domains) (empty? domains))
true
(let [[_ candidate] (-> (str/lower email)
(str/split #"@" 2))]
(contains? domains candidate)))))

View File

@@ -9,7 +9,6 @@
[app.common.exceptions :as ex]
[app.common.logging :as l]
[app.common.spec :as us]
[app.config :as cf]
[clj-ldap.client :as ldap]
[clojure.spec.alpha :as s]
[clojure.string]
@@ -104,17 +103,17 @@
nil))))
(s/def ::enabled? ::us/boolean)
(s/def ::host ::cf/ldap-host)
(s/def ::port ::cf/ldap-port)
(s/def ::ssl ::cf/ldap-ssl)
(s/def ::tls ::cf/ldap-starttls)
(s/def ::query ::cf/ldap-user-query)
(s/def ::base-dn ::cf/ldap-base-dn)
(s/def ::bind-dn ::cf/ldap-bind-dn)
(s/def ::bind-password ::cf/ldap-bind-password)
(s/def ::attrs-email ::cf/ldap-attrs-email)
(s/def ::attrs-fullname ::cf/ldap-attrs-fullname)
(s/def ::attrs-username ::cf/ldap-attrs-username)
(s/def ::host ::us/string)
(s/def ::port ::us/integer)
(s/def ::ssl ::us/boolean)
(s/def ::tls ::us/boolean)
(s/def ::query ::us/string)
(s/def ::base-dn ::us/string)
(s/def ::bind-dn ::us/string)
(s/def ::bind-password ::us/string)
(s/def ::attrs-email ::us/string)
(s/def ::attrs-fullname ::us/string)
(s/def ::attrs-username ::us/string)
(s/def ::provider-params
(s/keys :opt-un [::host ::port
@@ -126,6 +125,7 @@
::attrs-email
::attrs-username
::attrs-fullname]))
(s/def ::provider
(s/nilable ::provider-params))

View File

@@ -7,7 +7,6 @@
(ns app.auth.oidc
"OIDC client implementation."
(:require
[app.auth :as auth]
[app.auth.oidc.providers :as-alias providers]
[app.common.data :as d]
[app.common.data.macros :as dm]
@@ -17,13 +16,17 @@
[app.common.uri :as u]
[app.config :as cf]
[app.db :as db]
[app.email.blacklist :as email.blacklist]
[app.email.whitelist :as email.whitelist]
[app.http.client :as http]
[app.http.errors :as errors]
[app.http.session :as session]
[app.loggers.audit :as audit]
[app.main :as-alias main]
[app.rpc :as rpc]
[app.rpc.commands.profile :as profile]
[app.setup :as-alias setup]
[app.tokens :as tokens]
[app.util.inet :as inet]
[app.util.json :as json]
[app.util.time :as dt]
[buddy.sign.jwk :as jwk]
@@ -32,6 +35,7 @@
[clojure.spec.alpha :as s]
[cuerdas.core :as str]
[integrant.core :as ig]
[ring.request :as rreq]
[ring.response :as-alias rres]))
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
@@ -129,8 +133,8 @@
(-> body json/decode :keys process-oidc-jwks)
(do
(l/warn :hint "unable to retrieve JWKs (unexpected response status code)"
:http-status status
:http-body body)
:response-status status
:response-body body)
nil)))
(catch Throwable cause
(l/warn :hint "unable to retrieve JWKs (unexpected exception)"
@@ -144,18 +148,18 @@
(when (contains? cf/flags :login-with-oidc)
(if-let [opts (prepare-oidc-opts cfg)]
(let [jwks (fetch-oidc-jwks cfg opts)]
(l/info :hint "provider initialized"
:provider "oidc"
:method (if (:discover? opts) "discover" "manual")
:client-id (:client-id opts)
:client-secret (obfuscate-string (:client-secret opts))
:scopes (str/join "," (:scopes opts))
:auth-uri (:auth-uri opts)
:user-uri (:user-uri opts)
:token-uri (:token-uri opts)
:roles-attr (:roles-attr opts)
:roles (:roles opts)
:keys (str/join "," (map str (keys jwks))))
(l/inf :hint "provider initialized"
:provider "oidc"
:method (if (:discover? opts) "discover" "manual")
:client-id (:client-id opts)
:client-secret (obfuscate-string (:client-secret opts))
:scopes (str/join "," (:scopes opts))
:auth-uri (:auth-uri opts)
:user-uri (:user-uri opts)
:token-uri (:token-uri opts)
:roles-attr (:roles-attr opts)
:roles (:roles opts)
:keys (str/join "," (map str (keys jwks))))
(assoc opts :jwks jwks))
(do
(l/warn :hint "unable to initialize auth provider, missing configuration" :provider "oidc")
@@ -179,10 +183,10 @@
(if (and (string? (:client-id opts))
(string? (:client-secret opts)))
(do
(l/info :hint "provider initialized"
:provider "google"
:client-id (:client-id opts)
:client-secret (obfuscate-string (:client-secret opts)))
(l/inf :hint "provider initialized"
:provider "google"
:client-id (:client-id opts)
:client-secret (obfuscate-string (:client-secret opts)))
opts)
(do
@@ -207,8 +211,9 @@
(ex/raise :type :internal
:code :unable-to-retrieve-github-emails
:hint "unable to retrieve github emails"
:http-status status
:http-body body))
:request-uri (:uri params)
:response-status status
:response-body body))
(->> body json/decode (filter :primary) first :email))))
@@ -233,10 +238,10 @@
(if (and (string? (:client-id opts))
(string? (:client-secret opts)))
(do
(l/info :hint "provider initialized"
:provider "github"
:client-id (:client-id opts)
:client-secret (obfuscate-string (:client-secret opts)))
(l/inf :hint "provider initialized"
:provider "github"
:client-id (:client-id opts)
:client-secret (obfuscate-string (:client-secret opts)))
opts)
(do
@@ -248,7 +253,7 @@
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
(defmethod ig/init-key ::providers/gitlab
[_ _]
[_ cfg]
(let [base (cf/get :gitlab-base-uri "https://gitlab.com")
opts {:base-uri base
:client-id (cf/get :gitlab-client-id)
@@ -257,17 +262,18 @@
:auth-uri (str base "/oauth/authorize")
:token-uri (str base "/oauth/token")
:user-uri (str base "/oauth/userinfo")
:jwks-uri (str base "/oauth/discovery/keys")
:name "gitlab"}]
(when (contains? cf/flags :login-with-gitlab)
(if (and (string? (:client-id opts))
(string? (:client-secret opts)))
(do
(l/info :hint "provider initialized"
:provider "gitlab"
:base-uri base
:client-id (:client-id opts)
:client-secret (obfuscate-string (:client-secret opts)))
opts)
(let [jwks (fetch-oidc-jwks cfg opts)]
(l/inf :hint "provider initialized"
:provider "gitlab"
:base-uri base
:client-id (:client-id opts)
:client-secret (obfuscate-string (:client-secret opts)))
(assoc opts :jwks jwks))
(do
(l/warn :hint "unable to initialize auth provider, missing configuration" :provider "gitlab")
@@ -283,12 +289,12 @@
(into [(keyword (:name provider) fitem)] (map keyword) items)))
(defn- build-redirect-uri
[{:keys [provider] :as cfg}]
[{:keys [::provider] :as cfg}]
(let [public (u/uri (cf/get :public-uri))]
(str (assoc public :path (str "/api/auth/oauth/" (:name provider) "/callback")))))
(defn- build-auth-uri
[{:keys [provider] :as cfg} state]
[{:keys [::provider] :as cfg} state]
(let [params {:client_id (:client-id provider)
:redirect_uri (build-redirect-uri cfg)
:response_type "code"
@@ -299,15 +305,19 @@
(assoc :query query)
(str))))
(defn- qualify-prop-key
[provider k]
(keyword (:name provider) (name k)))
(defn- qualify-props
[provider props]
(reduce-kv (fn [result k v]
(assoc result (keyword (:name provider) (name k)) v))
(assoc result (qualify-prop-key provider k) v))
{}
props))
(defn fetch-access-token
[{:keys [provider] :as cfg} code]
(defn- fetch-access-token
[{:keys [::provider] :as cfg} code]
(let [params {:client_id (:client-id provider)
:client_secret (:client-secret provider)
:code code
@@ -319,26 +329,31 @@
:uri (:token-uri provider)
:body (u/map->query-string params)}]
(l/trace :hint "request access token"
:provider (:name provider)
:client-id (:client-id provider)
:client-secret (obfuscate-string (:client-secret provider))
:grant-type (:grant_type params)
:redirect-uri (:redirect_uri params))
(l/trc :hint "fetch access token"
:provider (:name provider)
:client-id (:client-id provider)
:client-secret (obfuscate-string (:client-secret provider))
:grant-type (:grant_type params)
:redirect-uri (:redirect_uri params))
(let [{:keys [status body]} (http/req! cfg req {:sync? true})]
(l/trace :hint "access token response" :status status :body body)
(l/trc :hint "access token fetched" :status status :body body)
(if (= status 200)
(let [data (json/decode body)]
{:token/access (get data :access_token)
:token/id (get data :id_token)
:token/type (get data :token_type)})
(let [data (json/decode body)
data {:token/access (get data :access_token)
:token/id (get data :id_token)
:token/type (get data :token_type)}]
(l/trc :hint "access token fetched"
:token-id (:token/id data)
:token-type (:token/type data)
:token (:token/access data))
data)
(ex/raise :type :internal
:code :unable-to-retrieve-token
:hint "unable to retrieve token"
:http-status status
:http-body body)))))
:code :unable-to-fetch-access-token
:hint "unable to fetch access token"
:request-uri (:uri req)
:response-status status
:response-body body)))))
(defn- process-user-info
[provider tdata info]
@@ -364,10 +379,10 @@
:props props})))
(defn- fetch-user-info
[{:keys [provider] :as cfg} tdata]
(l/trace :hint "fetch user info"
:uri (:user-uri provider)
:token (obfuscate-string (:token/access tdata)))
[{:keys [::provider] :as cfg} tdata]
(l/trc :hint "fetch user info"
:uri (:user-uri provider)
:token (obfuscate-string (:token/access tdata)))
(let [params {:uri (:user-uri provider)
:headers {"Authorization" (str (:token/type tdata) " " (:token/access tdata))}
@@ -375,9 +390,9 @@
:method :get}
response (http/req! cfg params {:sync? true})]
(l/trace :hint "user info response"
:status (:status response)
:body (:body response))
(l/trc :hint "user info response"
:status (:status response)
:body (:body response))
(when-not (s/int-in-range? 200 300 (:status response))
(ex/raise :type :internal
@@ -389,7 +404,7 @@
(-> response :body json/decode)))
(defn- get-user-info
[{:keys [provider]} tdata]
[{:keys [::provider]} tdata]
(try
(when (:token/id tdata)
(let [{:keys [kid alg] :as theader} (jwt/decode-header (:token/id tdata))]
@@ -413,14 +428,8 @@
::fullname
::props]))
(defn get-info
[{:keys [provider ::setup/props] :as cfg} {:keys [params] :as request}]
(when-let [error (get params :error)]
(ex/raise :type :internal
:code :error-on-retrieving-code
:error-id error
:error-desc (get params :error_description)))
(defn- get-info
[{:keys [::provider ::setup/props] :as cfg} {:keys [params] :as request}]
(let [state (get params :state)
code (get params :code)
state (tokens/verify props {:token state :iss :oauth})
@@ -433,7 +442,7 @@
info (process-user-info provider tdata info)]
(l/trace :hint "user info" :info info)
(l/trc :hint "user info" :info info)
(when-not (s/valid? ::info info)
(l/warn :hint "received incomplete profile info object (please set correct scopes)" :info info)
@@ -466,110 +475,172 @@
(some? (:invitation-token state))
(assoc :invitation-token (:invitation-token state))
(some? (:external-session-id state))
(assoc :external-session-id (:external-session-id state))
;; If state token comes with props, merge them. The state token
;; props can contain pm_ and utm_ prefixed query params.
(map? (:props state))
(update :props merge (:props state)))))
(defn- get-profile
[{:keys [::db/pool] :as cfg} info]
(dm/with-open [conn (db/open pool)]
(some->> (:email info)
(profile/clean-email)
(profile/get-profile-by-email conn))))
[cfg info]
(db/run! cfg (fn [{:keys [::db/conn]}]
(some->> (:email info)
(profile/clean-email)
(profile/get-profile-by-email conn)))))
(defn- redirect-response
[uri]
{::rres/status 302
::rres/headers {"location" (str uri)}})
(defn- generate-error-redirect
[_ cause]
(let [data (if (ex/error? cause) (ex-data cause) nil)
code (or (:code data) :unexpected)
type (or (:type data) :internal)
hint (or (:hint data)
(if (ex/exception? cause)
(ex-message cause)
(str cause)))
(defn- redirect-with-error
([error] (redirect-with-error error nil))
([error hint]
(let [params {:error error :hint hint}
params (d/without-nils params)
uri (-> (u/uri (cf/get :public-uri))
(assoc :path "/#/auth/login")
(assoc :query (u/map->query-string params)))]
(redirect-response uri))))
params {:error "unable-to-auth"
:hint hint
:type type
:code code}
(defn- redirect-to-register
[cfg info request]
(let [info (assoc info
:iss :prepared-register
:exp (dt/in-future {:hours 48}))
params {:token (tokens/generate (::setup/props cfg) info)
:provider (:provider (:path-params request))
:fullname (:fullname info)}
params (d/without-nils params)]
(redirect-response
(-> (u/uri (cf/get :public-uri))
(assoc :path "/#/auth/register/validate")
(assoc :query (u/map->query-string params))))))
(defn- redirect-to-verify-token
[token]
(let [params {:token token}
uri (-> (u/uri (cf/get :public-uri))
(assoc :path "/#/auth/login")
(assoc :path "/#/auth/verify-token")
(assoc :query (u/map->query-string params)))]
(redirect-response uri)))
(defn- generate-redirect
(defn- provider-has-email-verified?
[{:keys [::provider] :as cfg} {:keys [props] :as info}]
(let [prop (qualify-prop-key provider :email_verified)]
(true? (get props prop))))
(defn- profile-has-provider-props?
[{:keys [::provider] :as cfg} profile]
(let [prop (qualify-prop-key provider :email)]
(contains? (:props profile) prop)))
(defn- provider-matches-profile?
[{:keys [::provider] :as cfg} profile info]
(or (= (:auth-backend profile) (:name provider))
(profile-has-provider-props? cfg profile)
(provider-has-email-verified? cfg info)))
(defn- process-callback
[cfg request info profile]
(if profile
(let [sxf (session/create-fn cfg (:id profile))
token (or (:invitation-token info)
(tokens/generate (::setup/props cfg)
{:iss :auth
:exp (dt/in-future "15m")
:profile-id (:id profile)}))
params {:token token}
uri (-> (u/uri (cf/get :public-uri))
(assoc :path "/#/auth/verify-token")
(assoc :query (u/map->query-string params)))]
(cond
(some? profile)
(cond
(:is-blocked profile)
(redirect-with-error "profile-blocked")
(when (:is-blocked profile)
(ex/raise :type :restriction
:code :profile-blocked))
(not (provider-matches-profile? cfg profile info))
(redirect-with-error "auth-provider-not-allowed")
(audit/submit! cfg {::audit/type "command"
::audit/name "login-with-oidc"
::audit/profile-id (:id profile)
::audit/ip-addr (audit/parse-client-ip request)
::audit/props (audit/profile->props profile)})
(not (:is-active profile))
(let [info (assoc info :profile-id (:id profile))]
(redirect-to-register cfg info request))
(->> (redirect-response uri)
(sxf request)))
:else
(let [sxf (session/create-fn cfg (:id profile))
token (or (:invitation-token info)
(tokens/generate (::setup/props cfg)
{:iss :auth
:exp (dt/in-future "15m")
:profile-id (:id profile)}))
props (audit/profile->props profile)
context (d/without-nils {:external-session-id (:external-session-id info)})]
(audit/submit! cfg {::audit/type "action"
::audit/name "login-with-oidc"
::audit/profile-id (:id profile)
::audit/ip-addr (inet/parse-request request)
::audit/props props
::audit/context context})
(if (auth/email-domain-in-whitelist? (:email info))
(let [info (assoc info
:iss :prepared-register
:is-active true
:exp (dt/in-future {:hours 48}))
token (tokens/generate (::setup/props cfg) info)
params (d/without-nils
{:token token
:fullname (:fullname info)})
uri (-> (u/uri (cf/get :public-uri))
(assoc :path "/#/auth/register/validate")
(assoc :query (u/map->query-string params)))]
(->> (redirect-to-verify-token token)
(sxf request))))
(redirect-response uri))
(generate-error-redirect cfg "email-domain-not-allowed"))))
(and (email.blacklist/enabled? cfg)
(email.blacklist/contains? cfg (:email info)))
(redirect-with-error "email-domain-not-allowed")
(and (email.whitelist/enabled? cfg)
(not (email.whitelist/contains? cfg (:email info))))
(redirect-with-error "email-domain-not-allowed")
:else
(let [info (assoc info :is-active (provider-has-email-verified? cfg info))]
(if (or (contains? cf/flags :registration)
(contains? cf/flags :oidc-registration))
(redirect-to-register cfg info request)
(redirect-with-error "registration-disabled")))))
(defn- get-external-session-id
[request]
(let [session-id (rreq/get-header request "x-external-session-id")]
(when (string? session-id)
(if (or (> (count session-id) 256)
(= session-id "null")
(str/blank? session-id))
nil
session-id))))
(defn- auth-handler
[cfg {:keys [params] :as request}]
(let [props (audit/extract-utm-params params)
state (tokens/generate (::setup/props cfg)
{:iss :oauth
:invitation-token (:invitation-token params)
:props props
:exp (dt/in-future "4h")})
uri (build-auth-uri cfg state)]
(let [props (audit/extract-utm-params params)
esid (rpc/get-external-session-id request)
params {:iss :oauth
:invitation-token (:invitation-token params)
:external-session-id esid
:props props
:exp (dt/in-future "4h")}
state (tokens/generate (::setup/props cfg)
(d/without-nils params))
uri (build-auth-uri cfg state)]
{::rres/status 200
::rres/body {:redirect-uri uri}}))
(defn- callback-handler
[cfg request]
[{:keys [::provider] :as cfg} request]
(try
(let [info (get-info cfg request)
profile (get-profile cfg info)]
(generate-redirect cfg request info profile))
(if-let [error (dm/get-in request [:params :error])]
(redirect-with-error "unable-to-auth" error)
(let [info (get-info cfg request)
profile (get-profile cfg info)]
(process-callback cfg request info profile)))
(catch Throwable cause
(l/warn :hint "error on oauth process" :cause cause)
(generate-error-redirect cfg cause))))
(binding [l/*context* (-> (errors/request->context request)
(assoc :auth/provider (:name provider)))]
(let [edata (ex-data cause)]
(cond
(= :validation (:type edata))
(l/wrn :hint "invalid token received" :cause cause)
:else
(l/err :hint "error on oauth process" :cause cause))))
(redirect-with-error "unable-to-auth" (ex-message cause)))))
(def provider-lookup
{:compile
@@ -578,26 +649,24 @@
(fn [request]
(let [provider (some-> request :path-params :provider keyword)]
(if-let [provider (get providers provider)]
(handler (assoc cfg :provider provider) request)
(handler (assoc cfg ::provider provider) request)
(ex/raise :type :restriction
:code :provider-not-configured
:provider provider
:hint "provider not configured"))))))})
(s/def ::client-id ::us/string)
(s/def ::client-secret ::us/string)
(s/def ::base-uri ::us/string)
(s/def ::token-uri ::us/string)
(s/def ::auth-uri ::us/string)
(s/def ::user-uri ::us/string)
(s/def ::scopes ::us/set-of-strings)
(s/def ::roles ::us/set-of-strings)
(s/def ::roles-attr ::us/string)
(s/def ::email-attr ::us/string)
(s/def ::name-attr ::us/string)
(s/def ::client-id ::cf/oidc-client-id)
(s/def ::client-secret ::cf/oidc-client-secret)
(s/def ::base-uri ::cf/oidc-base-uri)
(s/def ::token-uri ::cf/oidc-token-uri)
(s/def ::auth-uri ::cf/oidc-auth-uri)
(s/def ::user-uri ::cf/oidc-user-uri)
(s/def ::scopes ::cf/oidc-scopes)
(s/def ::roles ::cf/oidc-roles)
(s/def ::roles-attr ::cf/oidc-roles-attr)
(s/def ::email-attr ::cf/oidc-email-attr)
(s/def ::name-attr ::cf/oidc-name-attr)
;; FIXME: migrate to qualified-keywords
(s/def ::provider
(s/keys :req-un [::client-id
::client-secret]

View File

@@ -15,6 +15,7 @@
[app.common.files.migrations :as fmg]
[app.common.files.validate :as fval]
[app.common.logging :as l]
[app.common.types.file :as ctf]
[app.common.uuid :as uuid]
[app.config :as cf]
[app.db :as db]
@@ -331,54 +332,12 @@
(defn embed-assets
[cfg data file-id]
(letfn [(walk-map-form [form state]
(cond
(uuid? (:fill-color-ref-file form))
(do
(vswap! state conj [(:fill-color-ref-file form) :colors (:fill-color-ref-id form)])
(assoc form :fill-color-ref-file file-id))
(uuid? (:stroke-color-ref-file form))
(do
(vswap! state conj [(:stroke-color-ref-file form) :colors (:stroke-color-ref-id form)])
(assoc form :stroke-color-ref-file file-id))
(uuid? (:typography-ref-file form))
(do
(vswap! state conj [(:typography-ref-file form) :typographies (:typography-ref-id form)])
(assoc form :typography-ref-file file-id))
(uuid? (:component-file form))
(do
(vswap! state conj [(:component-file form) :components (:component-id form)])
(assoc form :component-file file-id))
:else
form))
(process-group-of-assets [data [lib-id items]]
;; NOTE: there is a possibility that shape refers to an
;; non-existant file because the file was removed. In this
;; case we just ignore the asset.
(if-let [lib (get-file cfg lib-id)]
(reduce (partial process-asset lib) data items)
data))
(process-asset [lib data [bucket asset-id]]
(let [asset (get-in lib [:data bucket asset-id])
;; Add a special case for colors that need to have
;; correctly set the :file-id prop (pending of the
;; refactor that will remove it).
asset (cond-> asset
(= bucket :colors) (assoc :file-id file-id))]
(update data bucket assoc asset-id asset)))]
(let [assets (volatile! [])]
(walk/postwalk #(cond-> % (map? %) (walk-map-form assets)) data)
(->> (deref assets)
(filter #(as-> (first %) $ (and (uuid? $) (not= $ file-id))))
(d/group-by first rest)
(reduce (partial process-group-of-assets) data)))))
(let [library-ids (get-libraries cfg [file-id])]
(reduce (fn [data library-id]
(let [library (get-file cfg library-id)]
(ctf/absorb-assets data (:data library))))
data
library-ids)))
(defn- fix-version
[file]

View File

@@ -22,7 +22,6 @@
[app.db :as db]
[app.loggers.audit :as-alias audit]
[app.loggers.webhooks :as-alias webhooks]
[app.media :as media]
[app.rpc :as-alias rpc]
[app.rpc.commands.teams :as teams]
[app.rpc.doc :as-alias doc]
@@ -130,7 +129,6 @@
(.writeLong output (long data))
(swap! *position* + 8))
(defn read-long!
[^DataInputStream input]
(let [v (.readLong input)]
@@ -404,9 +402,9 @@
(write-obj! output rels)))
(defmethod write-section :v1/sobjects
[{:keys [::sto/storage ::output]}]
[{:keys [::output] :as cfg}]
(let [sids (-> bfc/*state* deref :sids)
storage (media/configure-assets-storage storage)]
storage (sto/resolve cfg)]
(l/dbg :hint "found sobjects"
:items (count sids)
@@ -621,8 +619,8 @@
::l/sync? true))))))
(defmethod read-section :v1/sobjects
[{:keys [::sto/storage ::db/conn ::input ::bfc/overwrite ::bfc/timestamp]}]
(let [storage (media/configure-assets-storage storage)
[{:keys [::db/conn ::input ::bfc/overwrite ::bfc/timestamp] :as cfg}]
(let [storage (sto/resolve cfg)
ids (read-obj! input)
thumb? (into #{} (map :media-id) (:thumbnails @bfc/*state*))]

View File

@@ -20,7 +20,6 @@
[app.db.sql :as sql]
[app.loggers.audit :as-alias audit]
[app.loggers.webhooks :as-alias webhooks]
[app.media :as media]
[app.storage :as sto]
[app.storage.tmp :as tmp]
[app.util.events :as events]
@@ -347,9 +346,7 @@
[cfg team-id]
(let [id (uuid/next)
tp (dt/tpoint)
cfg (-> (create-database cfg)
(update ::sto/storage media/configure-assets-storage))]
cfg (create-database cfg)]
(l/inf :hint "start"
:operation "export"
@@ -390,7 +387,6 @@
tp (dt/tpoint)
cfg (-> (create-database cfg path)
(update ::sto/storage media/configure-assets-storage)
(assoc ::bfc/timestamp (dt/now)))]
(l/inf :hint "start"

View File

@@ -11,30 +11,17 @@
[app.common.data :as d]
[app.common.exceptions :as ex]
[app.common.flags :as flags]
[app.common.spec :as us]
[app.common.schema :as sm]
[app.common.version :as v]
[app.util.overrides]
[app.util.time :as dt]
[clojure.core :as c]
[clojure.java.io :as io]
[clojure.pprint :as pprint]
[clojure.spec.alpha :as s]
[cuerdas.core :as str]
[datoteka.fs :as fs]
[environ.core :refer [env]]
[integrant.core :as ig]))
(prefer-method print-method
clojure.lang.IRecord
clojure.lang.IDeref)
(prefer-method print-method
clojure.lang.IPersistentMap
clojure.lang.IDeref)
(prefer-method pprint/simple-dispatch
clojure.lang.IPersistentMap
clojure.lang.IDeref)
(defmethod ig/init-key :default
[_ data]
(d/without-nils data))
@@ -45,18 +32,19 @@
(d/without-nils data)
data))
(def defaults
(def default
{:database-uri "postgresql://postgres/penpot"
:database-username "penpot"
:database-password "penpot"
:default-blob-version 5
:default-blob-version 4
:rpc-rlimit-config (fs/path "resources/rlimit.edn")
:rpc-climit-config (fs/path "resources/climit.edn")
:rpc-rlimit-config "resources/rlimit.edn"
:rpc-climit-config "resources/climit.edn"
:file-change-snapshot-every 5
:file-change-snapshot-timeout "3h"
:auto-file-snapshot-total 10
:auto-file-snapshot-every 5
:auto-file-snapshot-timeout "3h"
:public-uri "http://localhost:3449"
:host "localhost"
@@ -64,8 +52,8 @@
:redis-uri "redis://redis/0"
:assets-storage-backend :assets-fs
:storage-assets-fs-directory "assets"
:objects-storage-backend "fs"
:objects-storage-fs-directory "assets"
:assets-path "/internal/assets/"
:smtp-default-reply-to "Penpot <no-reply@example.com>"
@@ -87,251 +75,156 @@
:ldap-attrs-fullname "cn"
;; a server prop key where initial project is stored.
:initial-project-skey "initial-project"})
:initial-project-skey "initial-project"
(s/def ::default-rpc-rlimit ::us/vector-of-strings)
(s/def ::rpc-rlimit-config ::fs/path)
(s/def ::rpc-climit-config ::fs/path)
;; time to avoid email sending after profile modification
:email-verify-threshold "15m"})
(s/def ::media-max-file-size ::us/integer)
(def schema:config
(do #_sm/optional-keys
[:map {:title "config"}
[:flags {:optional true} [::sm/set :string]]
[:admins {:optional true} [::sm/set ::sm/email]]
[:secret-key {:optional true} :string]
(s/def ::flags ::us/vector-of-keywords)
(s/def ::telemetry-enabled ::us/boolean)
[:tenant {:optional false} :string]
[:public-uri {:optional false} :string]
[:host {:optional false} :string]
(s/def ::audit-log-archive-uri ::us/string)
(s/def ::audit-log-http-handler-concurrency ::us/integer)
[:http-server-port {:optional true} ::sm/int]
[:http-server-host {:optional true} :string]
[:http-server-max-body-size {:optional true} ::sm/int]
[:http-server-max-multipart-body-size {:optional true} ::sm/int]
[:http-server-io-threads {:optional true} ::sm/int]
[:http-server-worker-threads {:optional true} ::sm/int]
(s/def ::deletion-delay ::dt/duration)
[:telemetry-uri {:optional true} :string]
[:telemetry-with-taiga {:optional true} ::sm/boolean] ;; DELETE
(s/def ::admins ::us/set-of-valid-emails)
(s/def ::file-change-snapshot-every ::us/integer)
(s/def ::file-change-snapshot-timeout ::dt/duration)
[:auto-file-snapshot-total {:optional true} ::sm/int]
[:auto-file-snapshot-every {:optional true} ::sm/int]
[:auto-file-snapshot-timeout {:optional true} ::dt/duration]
(s/def ::default-executor-parallelism ::us/integer)
(s/def ::scheduled-executor-parallelism ::us/integer)
[:media-max-file-size {:optional true} ::sm/int]
[:deletion-delay {:optional true} ::dt/duration] ;; REVIEW
[:telemetry-enabled {:optional true} ::sm/boolean]
[:default-blob-version {:optional true} ::sm/int]
[:allow-demo-users {:optional true} ::sm/boolean]
[:error-report-webhook {:optional true} :string]
[:user-feedback-destination {:optional true} :string]
(s/def ::worker-default-parallelism ::us/integer)
(s/def ::worker-webhook-parallelism ::us/integer)
[:default-rpc-rlimit {:optional true} [::sm/vec :string]]
[:rpc-rlimit-config {:optional true} ::fs/path]
[:rpc-climit-config {:optional true} ::fs/path]
(s/def ::authenticated-cookie-domain ::us/string)
(s/def ::authenticated-cookie-name ::us/string)
(s/def ::auth-token-cookie-name ::us/string)
(s/def ::auth-token-cookie-max-age ::dt/duration)
[:audit-log-archive-uri {:optional true} :string]
[:audit-log-http-handler-concurrency {:optional true} ::sm/int]
(s/def ::secret-key ::us/string)
(s/def ::allow-demo-users ::us/boolean)
(s/def ::assets-path ::us/string)
(s/def ::database-password (s/nilable ::us/string))
(s/def ::database-uri ::us/string)
(s/def ::database-username (s/nilable ::us/string))
(s/def ::database-readonly ::us/boolean)
(s/def ::database-min-pool-size ::us/integer)
(s/def ::database-max-pool-size ::us/integer)
[:default-executor-parallelism {:optional true} ::sm/int] ;; REVIEW
[:scheduled-executor-parallelism {:optional true} ::sm/int] ;; REVIEW
[:worker-default-parallelism {:optional true} ::sm/int]
[:worker-webhook-parallelism {:optional true} ::sm/int]
(s/def ::quotes-teams-per-profile ::us/integer)
(s/def ::quotes-access-tokens-per-profile ::us/integer)
(s/def ::quotes-projects-per-team ::us/integer)
(s/def ::quotes-invitations-per-team ::us/integer)
(s/def ::quotes-profiles-per-team ::us/integer)
(s/def ::quotes-files-per-project ::us/integer)
(s/def ::quotes-files-per-team ::us/integer)
(s/def ::quotes-font-variants-per-team ::us/integer)
(s/def ::quotes-comment-threads-per-file ::us/integer)
(s/def ::quotes-comments-per-file ::us/integer)
[:database-password {:optional true} [:maybe :string]]
[:database-uri {:optional true} :string]
[:database-username {:optional true} [:maybe :string]]
[:database-readonly {:optional true} ::sm/boolean]
[:database-min-pool-size {:optional true} ::sm/int]
[:database-max-pool-size {:optional true} ::sm/int]
(s/def ::default-blob-version ::us/integer)
(s/def ::error-report-webhook ::us/string)
(s/def ::user-feedback-destination ::us/string)
(s/def ::github-client-id ::us/string)
(s/def ::github-client-secret ::us/string)
(s/def ::gitlab-base-uri ::us/string)
(s/def ::gitlab-client-id ::us/string)
(s/def ::gitlab-client-secret ::us/string)
(s/def ::google-client-id ::us/string)
(s/def ::google-client-secret ::us/string)
(s/def ::oidc-client-id ::us/string)
(s/def ::oidc-user-info-source ::us/keyword)
(s/def ::oidc-client-secret ::us/string)
(s/def ::oidc-base-uri ::us/string)
(s/def ::oidc-token-uri ::us/string)
(s/def ::oidc-auth-uri ::us/string)
(s/def ::oidc-user-uri ::us/string)
(s/def ::oidc-jwks-uri ::us/string)
(s/def ::oidc-scopes ::us/set-of-strings)
(s/def ::oidc-roles ::us/set-of-strings)
(s/def ::oidc-roles-attr ::us/string)
(s/def ::oidc-email-attr ::us/string)
(s/def ::oidc-name-attr ::us/string)
(s/def ::host ::us/string)
(s/def ::http-server-port ::us/integer)
(s/def ::http-server-host ::us/string)
(s/def ::http-server-max-body-size ::us/integer)
(s/def ::http-server-max-multipart-body-size ::us/integer)
(s/def ::http-server-io-threads ::us/integer)
(s/def ::http-server-worker-threads ::us/integer)
(s/def ::ldap-attrs-email ::us/string)
(s/def ::ldap-attrs-fullname ::us/string)
(s/def ::ldap-attrs-username ::us/string)
(s/def ::ldap-base-dn ::us/string)
(s/def ::ldap-bind-dn ::us/string)
(s/def ::ldap-bind-password ::us/string)
(s/def ::ldap-host ::us/string)
(s/def ::ldap-port ::us/integer)
(s/def ::ldap-ssl ::us/boolean)
(s/def ::ldap-starttls ::us/boolean)
(s/def ::ldap-user-query ::us/string)
(s/def ::media-directory ::us/string)
(s/def ::media-uri ::us/string)
(s/def ::profile-bounce-max-age ::dt/duration)
(s/def ::profile-bounce-threshold ::us/integer)
(s/def ::profile-complaint-max-age ::dt/duration)
(s/def ::profile-complaint-threshold ::us/integer)
(s/def ::public-uri ::us/string)
(s/def ::redis-uri ::us/string)
(s/def ::registration-domain-whitelist ::us/set-of-strings)
[:quotes-teams-per-profile {:optional true} ::sm/int]
[:quotes-access-tokens-per-profile {:optional true} ::sm/int]
[:quotes-projects-per-team {:optional true} ::sm/int]
[:quotes-invitations-per-team {:optional true} ::sm/int]
[:quotes-profiles-per-team {:optional true} ::sm/int]
[:quotes-files-per-project {:optional true} ::sm/int]
[:quotes-files-per-team {:optional true} ::sm/int]
[:quotes-font-variants-per-team {:optional true} ::sm/int]
[:quotes-comment-threads-per-file {:optional true} ::sm/int]
[:quotes-comments-per-file {:optional true} ::sm/int]
(s/def ::smtp-default-from ::us/string)
(s/def ::smtp-default-reply-to ::us/string)
(s/def ::smtp-host ::us/string)
(s/def ::smtp-password (s/nilable ::us/string))
(s/def ::smtp-port ::us/integer)
(s/def ::smtp-ssl ::us/boolean)
(s/def ::smtp-tls ::us/boolean)
(s/def ::smtp-username (s/nilable ::us/string))
(s/def ::urepl-host ::us/string)
(s/def ::urepl-port ::us/integer)
(s/def ::prepl-host ::us/string)
(s/def ::prepl-port ::us/integer)
(s/def ::assets-storage-backend ::us/keyword)
(s/def ::storage-assets-fs-directory ::us/string)
(s/def ::storage-assets-s3-bucket ::us/string)
(s/def ::storage-assets-s3-region ::us/keyword)
(s/def ::storage-assets-s3-endpoint ::us/string)
(s/def ::storage-assets-s3-io-threads ::us/integer)
(s/def ::telemetry-uri ::us/string)
(s/def ::telemetry-with-taiga ::us/boolean)
(s/def ::tenant ::us/string)
[:auth-data-cookie-domain {:optional true} :string]
[:auth-token-cookie-name {:optional true} :string]
[:auth-token-cookie-max-age {:optional true} ::dt/duration]
(s/def ::config
(s/keys :opt-un [::secret-key
::flags
::admins
::deletion-delay
::allow-demo-users
::audit-log-archive-uri
::audit-log-http-handler-concurrency
::auth-token-cookie-name
::auth-token-cookie-max-age
::authenticated-cookie-name
::authenticated-cookie-domain
::database-password
::database-uri
::database-username
::database-readonly
::database-min-pool-size
::database-max-pool-size
::default-blob-version
::default-rpc-rlimit
::error-report-webhook
::default-executor-parallelism
::scheduled-executor-parallelism
::worker-default-parallelism
::worker-webhook-parallelism
::file-change-snapshot-every
::file-change-snapshot-timeout
::user-feedback-destination
::github-client-id
::github-client-secret
::gitlab-base-uri
::gitlab-client-id
::gitlab-client-secret
::google-client-id
::google-client-secret
::oidc-client-id
::oidc-client-secret
::oidc-user-info-source
::oidc-base-uri
::oidc-token-uri
::oidc-auth-uri
::oidc-user-uri
::oidc-jwks-uri
::oidc-scopes
::oidc-roles-attr
::oidc-email-attr
::oidc-name-attr
::oidc-roles
::host
::http-server-host
::http-server-port
::http-server-max-body-size
::http-server-max-multipart-body-size
::http-server-io-threads
::http-server-worker-threads
::ldap-attrs-email
::ldap-attrs-fullname
::ldap-attrs-username
::ldap-base-dn
::ldap-bind-dn
::ldap-bind-password
::ldap-host
::ldap-port
::ldap-ssl
::ldap-starttls
::ldap-user-query
::local-assets-uri
::media-max-file-size
::profile-bounce-max-age
::profile-bounce-threshold
::profile-complaint-max-age
::profile-complaint-threshold
::public-uri
[:registration-domain-whitelist {:optional true} [::sm/set :string]]
[:email-verify-threshold {:optional true} ::dt/duration]
::quotes-teams-per-profile
::quotes-access-tokens-per-profile
::quotes-projects-per-team
::quotes-invitations-per-team
::quotes-profiles-per-team
::quotes-files-per-project
::quotes-files-per-team
::quotes-font-variants-per-team
::quotes-comment-threads-per-file
::quotes-comments-per-file
[:github-client-id {:optional true} :string]
[:github-client-secret {:optional true} :string]
[:gitlab-base-uri {:optional true} :string]
[:gitlab-client-id {:optional true} :string]
[:gitlab-client-secret {:optional true} :string]
[:google-client-id {:optional true} :string]
[:google-client-secret {:optional true} :string]
[:oidc-client-id {:optional true} :string]
[:oidc-user-info-source {:optional true} :keyword]
[:oidc-client-secret {:optional true} :string]
[:oidc-base-uri {:optional true} :string]
[:oidc-token-uri {:optional true} :string]
[:oidc-auth-uri {:optional true} :string]
[:oidc-user-uri {:optional true} :string]
[:oidc-jwks-uri {:optional true} :string]
[:oidc-scopes {:optional true} [::sm/set :string]]
[:oidc-roles {:optional true} [::sm/set :string]]
[:oidc-roles-attr {:optional true} :string]
[:oidc-email-attr {:optional true} :string]
[:oidc-name-attr {:optional true} :string]
::redis-uri
::registration-domain-whitelist
::rpc-rlimit-config
::rpc-climit-config
[:ldap-attrs-email {:optional true} :string]
[:ldap-attrs-fullname {:optional true} :string]
[:ldap-attrs-username {:optional true} :string]
[:ldap-base-dn {:optional true} :string]
[:ldap-bind-dn {:optional true} :string]
[:ldap-bind-password {:optional true} :string]
[:ldap-host {:optional true} :string]
[:ldap-port {:optional true} ::sm/int]
[:ldap-ssl {:optional true} ::sm/boolean]
[:ldap-starttls {:optional true} ::sm/boolean]
[:ldap-user-query {:optional true} :string]
::semaphore-process-font
::semaphore-process-image
::semaphore-update-file
::semaphore-auth
[:profile-bounce-max-age {:optional true} ::dt/duration]
[:profile-bounce-threshold {:optional true} ::sm/int]
[:profile-complaint-max-age {:optional true} ::dt/duration]
[:profile-complaint-threshold {:optional true} ::sm/int]
::smtp-default-from
::smtp-default-reply-to
::smtp-host
::smtp-password
::smtp-port
::smtp-ssl
::smtp-tls
::smtp-username
[:redis-uri {:optional true} :string]
::urepl-host
::urepl-port
::prepl-host
::prepl-port
[:email-domain-blacklist {:optional true} ::fs/path]
[:email-domain-whitelist {:optional true} ::fs/path]
::assets-storage-backend
::storage-assets-fs-directory
::storage-assets-s3-bucket
::storage-assets-s3-region
::storage-assets-s3-endpoint
::storage-assets-s3-io-threads
::telemetry-enabled
::telemetry-uri
::telemetry-referer
::telemetry-with-taiga
::tenant]))
[:smtp-default-from {:optional true} :string]
[:smtp-default-reply-to {:optional true} :string]
[:smtp-host {:optional true} :string]
[:smtp-password {:optional true} [:maybe :string]]
[:smtp-port {:optional true} ::sm/int]
[:smtp-ssl {:optional true} ::sm/boolean]
[:smtp-tls {:optional true} ::sm/boolean]
[:smtp-username {:optional true} [:maybe :string]]
[:urepl-host {:optional true} :string]
[:urepl-port {:optional true} ::sm/int]
[:prepl-host {:optional true} :string]
[:prepl-port {:optional true} ::sm/int]
[:media-directory {:optional true} :string] ;; REVIEW
[:media-uri {:optional true} :string]
[:assets-path {:optional true} :string]
;; Legacy, will be removed in 2.5
[:assets-storage-backend {:optional true} :keyword]
[:storage-assets-fs-directory {:optional true} :string]
[:storage-assets-s3-bucket {:optional true} :string]
[:storage-assets-s3-region {:optional true} :keyword]
[:storage-assets-s3-endpoint {:optional true} :string]
[:storage-assets-s3-io-threads {:optional true} ::sm/int]
[:objects-storage-backend {:optional true} :keyword]
[:objects-storage-fs-directory {:optional true} :string]
[:objects-storage-s3-bucket {:optional true} :string]
[:objects-storage-s3-region {:optional true} :keyword]
[:objects-storage-s3-endpoint {:optional true} :string]
[:objects-storage-s3-io-threads {:optional true} ::sm/int]]))
(def default-flags
[:enable-backend-api-doc
@@ -359,20 +252,22 @@
{}
env)))
(defn- read-config
[]
(try
(->> (read-env "penpot")
(merge defaults)
(us/conform ::config))
(catch Throwable e
(when (ex/error? e)
(println ";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;")
(println "Error on validating configuration:")
(println (some-> e ex-data ex/explain))
(println (ex/explain (ex-data e)))
(println ";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"))
(throw e))))
(def decode-config
(sm/decoder schema:config sm/string-transformer))
(def validate-config
(sm/validator schema:config))
(def explain-config
(sm/explainer schema:config))
(defn read-config
"Reads the configuration from enviroment variables and decodes all
known values."
[& {:keys [prefix default] :or {prefix "penpot"}}]
(->> (read-env prefix)
(merge default)
(decode-config)))
(def version
(v/parse (or (some-> (io/resource "version.txt")
@@ -380,10 +275,28 @@
(str/trim))
"%version%")))
(defonce ^:dynamic config (read-config))
(defonce ^:dynamic config (read-config :default default))
(defonce ^:dynamic flags (parse-flags config))
(def deletion-delay
(defn validate!
"Validate the currently loaded configuration data."
[& {:keys [exit-on-error?] :or {exit-on-error? true}}]
(if (validate-config config)
true
(let [explain (explain-config config)]
(println "Error on validating configuration:")
(sm/pretty-explain explain
:variant ::sm/schemaless-explain
:message "Configuration Validation Error")
(flush)
(if exit-on-error?
(System/exit -1)
(ex/raise :type :validation
:code :config-validaton
::sm/explain explain)))))
(defn get-deletion-delay
[]
(or (c/get config :deletion-delay)
(dt/duration {:days 7})))

View File

@@ -153,7 +153,7 @@
(s/def ::conn some?)
(s/def ::nilable-pool (s/nilable ::pool))
(s/def ::pool pool?)
(s/def ::pool-or-conn some?)
(s/def ::connectable some?)
(defn closed?
[pool]
@@ -407,6 +407,7 @@
(ex/raise :type :not-found
:code :object-not-found
:table table
:params params
:hint "database object not found"))
row))

View File

@@ -7,14 +7,18 @@
(ns app.email
"Main api for send emails."
(:require
[app.common.data.macros :as dm]
[app.common.exceptions :as ex]
[app.common.logging :as l]
[app.common.pprint :as pp]
[app.common.schema :as sm]
[app.common.spec :as us]
[app.config :as cf]
[app.db :as db]
[app.db.sql :as sql]
[app.email.invite-to-team :as-alias email.invite-to-team]
[app.email.join-team :as-alias email.join-team]
[app.email.request-team-access :as-alias email.request-team-access]
[app.metrics :as mtx]
[app.util.template :as tmpl]
[app.worker :as wrk]
@@ -149,9 +153,27 @@
"mail.smtp.timeout" timeout
"mail.smtp.connectiontimeout" timeout}))
(def ^:private schema:smtp-config
[:map
[::username {:optional true} :string]
[::password {:optional true} :string]
[::tls {:optional true} ::sm/boolean]
[::ssl {:optional true} ::sm/boolean]
[::host {:optional true} :string]
[::port {:optional true} ::sm/int]
[::default-from {:optional true} :string]
[::default-reply-to {:optional true} :string]])
(def valid-smtp-config?
(sm/check-fn schema:smtp-config))
(defn- create-smtp-session
^Session
[cfg]
(dm/assert!
"expected valid smtp config"
(valid-smtp-config? cfg))
(let [props (opts->props cfg)]
(Session/getInstance props)))
@@ -262,44 +284,21 @@
(let [email (if factory
(factory context)
(dissoc context ::conn))]
(wrk/submit! (merge
{::wrk/task :sendmail
::wrk/delay 0
::wrk/max-retries 4
::wrk/priority 200
::wrk/conn conn}
email))))
(wrk/submit! {::wrk/task :sendmail
::wrk/delay 0
::wrk/max-retries 4
::wrk/priority 200
::db/conn conn
::wrk/params email})))
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;; SENDMAIL FN / TASK HANDLER
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
(s/def ::username ::cf/smtp-username)
(s/def ::password ::cf/smtp-password)
(s/def ::tls ::cf/smtp-tls)
(s/def ::ssl ::cf/smtp-ssl)
(s/def ::host ::cf/smtp-host)
(s/def ::port ::cf/smtp-port)
(s/def ::default-reply-to ::cf/smtp-default-reply-to)
(s/def ::default-from ::cf/smtp-default-from)
(s/def ::smtp-config
(s/keys :opt [::username
::password
::tls
::ssl
::host
::port
::default-from
::default-reply-to]))
(declare send-to-logger!)
(s/def ::sendmail fn?)
(defmethod ig/pre-init-spec ::sendmail [_]
(s/spec ::smtp-config))
(defmethod ig/init-key ::sendmail
[_ cfg]
(fn [params]
@@ -307,6 +306,8 @@
(let [session (create-smtp-session cfg)]
(with-open [transport (.getTransport session (if (::ssl cfg) "smtps" "smtp"))]
(.connect ^Transport transport
^String (::host cfg)
^String (::port cfg)
^String (::username cfg)
^String (::password cfg))
@@ -400,6 +401,79 @@
"Teams member invitation email."
(template-factory ::invite-to-team))
(s/def ::email.join-team/invited-by ::us/string)
(s/def ::email.join-team/team ::us/string)
(s/def ::email.join-team/team-id ::us/uuid)
(s/def ::join-team
(s/keys :req-un [::email.join-team/invited-by
::email.join-team/team-id
::email.join-team/team]))
(def join-team
"Teams member joined after request email."
(template-factory ::join-team))
(s/def ::email.request-team-access/requested-by ::us/string)
(s/def ::email.request-team-access/requested-by-email ::us/string)
(s/def ::email.request-team-access/team-name ::us/string)
(s/def ::email.request-team-access/team-id ::us/uuid)
(s/def ::email.request-team-access/file-name ::us/string)
(s/def ::email.request-team-access/file-id ::us/uuid)
(s/def ::email.request-team-access/page-id ::us/uuid)
(s/def ::request-file-access
(s/keys :req-un [::email.request-team-access/requested-by
::email.request-team-access/requested-by-email
::email.request-team-access/team-name
::email.request-team-access/team-id
::email.request-team-access/file-name
::email.request-team-access/file-id
::email.request-team-access/page-id]))
(def request-file-access
"File access request email."
(template-factory ::request-file-access))
(s/def ::request-file-access-yourpenpot
(s/keys :req-un [::email.request-team-access/requested-by
::email.request-team-access/requested-by-email
::email.request-team-access/team-name
::email.request-team-access/team-id
::email.request-team-access/file-name
::email.request-team-access/file-id
::email.request-team-access/page-id]))
(def request-file-access-yourpenpot
"File access on Your Penpot request email."
(template-factory ::request-file-access-yourpenpot))
(s/def ::request-file-access-yourpenpot-view
(s/keys :req-un [::email.request-team-access/requested-by
::email.request-team-access/requested-by-email
::email.request-team-access/team-name
::email.request-team-access/team-id
::email.request-team-access/file-name
::email.request-team-access/file-id
::email.request-team-access/page-id]))
(def request-file-access-yourpenpot-view
"File access on Your Penpot view mode request email."
(template-factory ::request-file-access-yourpenpot-view))
(s/def ::request-team-access
(s/keys :req-un [::email.request-team-access/requested-by
::email.request-team-access/requested-by-email
::email.request-team-access/team-name
::email.request-team-access/team-id]))
(def request-team-access
"Team access request email."
(template-factory ::request-team-access))
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;; BOUNCE/COMPLAINS HELPERS
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
@@ -449,3 +523,11 @@
{:email email :type "bounce"}
{:limit 10}))]
(>= (count reports) threshold))))
(defn has-reports?
([conn email] (has-reports? conn email nil))
([conn email {:keys [threshold] :or {threshold 1}}]
(let [reports (db/exec! conn (sql/select :global-complaint-report
{:email email}
{:limit 10}))]
(>= (count reports) threshold))))

View File

@@ -0,0 +1,47 @@
;; This Source Code Form is subject to the terms of the Mozilla Public
;; License, v. 2.0. If a copy of the MPL was not distributed with this
;; file, You can obtain one at http://mozilla.org/MPL/2.0/.
;;
;; Copyright (c) KALEIDOS INC
(ns app.email.blacklist
"Email blacklist provider"
(:refer-clojure :exclude [contains?])
(:require
[app.common.logging :as l]
[app.config :as cf]
[app.email :as-alias email]
[clojure.core :as c]
[clojure.java.io :as io]
[cuerdas.core :as str]
[integrant.core :as ig]))
(defmethod ig/init-key ::email/blacklist
[_ _]
(when (c/contains? cf/flags :email-blacklist)
(try
(let [path (cf/get :email-domain-blacklist)
result (with-open [reader (io/reader path)]
(reduce (fn [result line]
(if (str/starts-with? line "#")
result
(conj result (-> line str/trim str/lower))))
#{}
(line-seq reader)))]
(l/inf :hint "initializing email blacklist" :domains (count result))
(not-empty result))
(catch Throwable cause
(l/wrn :hint "unexpected exception on initializing email blacklist"
:cause cause)))))
(defn contains?
"Check if email is in the blacklist."
[{:keys [::email/blacklist]} email]
(let [[_ domain] (str/split email "@" 2)]
(c/contains? blacklist (str/lower domain))))
(defn enabled?
"Check if the blacklist is enabled"
[{:keys [::email/blacklist]}]
(some? blacklist))

View File

@@ -0,0 +1,59 @@
;; This Source Code Form is subject to the terms of the Mozilla Public
;; License, v. 2.0. If a copy of the MPL was not distributed with this
;; file, You can obtain one at http://mozilla.org/MPL/2.0/.
;;
;; Copyright (c) KALEIDOS INC
(ns app.email.whitelist
"Email whitelist provider"
(:refer-clojure :exclude [contains?])
(:require
[app.common.logging :as l]
[app.config :as cf]
[app.email :as-alias email]
[clojure.core :as c]
[clojure.java.io :as io]
[cuerdas.core :as str]
[datoteka.fs :as fs]
[integrant.core :as ig]))
(defn- read-whitelist
[path]
(when (and path (fs/exists? path))
(try
(with-open [reader (io/reader path)]
(reduce (fn [result line]
(if (str/starts-with? line "#")
result
(conj result (-> line str/trim str/lower))))
#{}
(line-seq reader)))
(catch Throwable cause
(l/wrn :hint "unexpected exception on reading email whitelist"
:cause cause)))))
(defmethod ig/init-key ::email/whitelist
[_ _]
(let [whitelist (or (cf/get :registration-domain-whitelist) #{})
whitelist (if (c/contains? cf/flags :email-whitelist)
(into whitelist (read-whitelist (cf/get :email-domain-whitelist)))
whitelist)
whitelist (not-empty whitelist)]
(when whitelist
(l/inf :hint "initializing email whitelist" :domains (count whitelist)))
whitelist))
(defn contains?
"Check if email is in the whitelist."
[{:keys [::email/whitelist]} email]
(let [[_ domain] (str/split email "@" 2)]
(c/contains? whitelist (str/lower domain))))
(defn enabled?
"Check if the whitelist is enabled"
[{:keys [::email/whitelist]}]
(some? whitelist))

View File

@@ -12,7 +12,6 @@
[app.common.files.changes :as cp]
[app.common.files.changes-builder :as fcb]
[app.common.files.helpers :as cfh]
[app.common.files.libraries-helpers :as cflh]
[app.common.files.migrations :as fmg]
[app.common.files.shapes-helpers :as cfsh]
[app.common.files.validate :as cfv]
@@ -23,6 +22,7 @@
[app.common.geom.shapes :as gsh]
[app.common.geom.shapes.path :as gshp]
[app.common.logging :as l]
[app.common.logic.libraries :as cll]
[app.common.math :as mth]
[app.common.schema :as sm]
[app.common.svg :as csvg]
@@ -62,6 +62,7 @@
[datoteka.io :as io]
[promesa.util :as pu]))
(def ^:dynamic *stats*
"A dynamic var for setting up state for collect stats globally."
nil)
@@ -113,7 +114,7 @@
(sm/lazy-validator ::ctc/color))
(def valid-fill?
(sm/lazy-validator ::cts/fill))
(sm/lazy-validator cts/schema:fill))
(def valid-stroke?
(sm/lazy-validator ::cts/stroke))
@@ -134,10 +135,10 @@
(sm/lazy-validator ::ctc/rgb-color))
(def valid-shape-points?
(sm/lazy-validator ::cts/points))
(sm/lazy-validator cts/schema:points))
(def valid-image-attrs?
(sm/lazy-validator ::cts/image-attrs))
(sm/lazy-validator cts/schema:image-attrs))
(def valid-column-grid-params?
(sm/lazy-validator ::ctg/column-params))
@@ -1450,16 +1451,15 @@
page
(cons shape children))
[_ _ changes2]
(cflh/generate-add-component nil
[shape]
(:objects page)
(:id page)
file-id
true
nil
cfsh/prepare-create-artboard-from-selection)
changes (fcb/concat-changes changes changes2)]
[_ _ changes]
(cll/generate-add-component changes
[shape]
(:objects page)
(:id page)
file-id
true
nil
cfsh/prepare-create-artboard-from-selection)]
(shape-cb shape)
(:redo-changes changes)))
@@ -1743,7 +1743,7 @@
:validate validate?
:skip-on-graphic-error skip-on-graphic-error?)
(db/tx-run! (update system ::sto/storage media/configure-assets-storage)
(db/tx-run! system
(fn [system]
(binding [*system* system]
(when (string? label)

View File

@@ -12,10 +12,19 @@
[app.common.logging :as l]
[app.db :as db]
[app.db.sql :as-alias sql]
[app.storage :as sto]
[app.util.blob :as blob]
[app.util.objects-map :as omap]
[app.util.pointer-map :as pmap]))
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;; OFFLOAD
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
(defn offloaded?
[file]
(= "objects-storage" (:data-backend file)))
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;; OBJECTS-MAP
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
@@ -55,31 +64,45 @@
;; POINTER-MAP
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
(defn get-file-data
"Get file data given a file instance."
[system file]
(if (offloaded? file)
(let [storage (sto/resolve system ::db/reuse-conn true)]
(->> (sto/get-object storage (:data-ref-id file))
(sto/get-object-bytes storage)))
(:data file)))
(defn resolve-file-data
[system file]
(let [data (get-file-data system file)]
(assoc file :data data)))
(defn load-pointer
"A database loader pointer helper"
[system file-id id]
(let [{:keys [content]} (db/get system :file-data-fragment
{:id id :file-id file-id}
{::sql/columns [:content]
::db/check-deleted false})]
(let [fragment (db/get* system :file-data-fragment
{:id id :file-id file-id}
{::sql/columns [:data :data-backend :data-ref-id :id]})]
(l/trc :hint "load pointer"
:file-id (str file-id)
:id (str id)
:found (some? content))
:found (some? fragment))
(when-not content
(when-not fragment
(ex/raise :type :internal
:code :fragment-not-found
:hint "fragment not found"
:file-id file-id
:fragment-id id))
(blob/decode content)))
(let [data (get-file-data system fragment)]
;; FIXME: conditional thread scheduling for decoding big objects
(blob/decode data))))
(defn persist-pointers!
"Given a database connection and the final file-id, persist all
pointers to the underlying storage (the database)."
"Persist all currently tracked pointer objects"
[system file-id]
(let [conn (db/get-connection system)]
(doseq [[id item] @pmap/*tracked*]
@@ -89,7 +112,7 @@
(db/insert! conn :file-data-fragment
{:id id
:file-id file-id
:content content}))))))
:data content}))))))
(defn process-pointers
"Apply a function to all pointers on the file. Usuly used for

View File

@@ -114,7 +114,7 @@
(partial not-found-handler request)))
(on-error [cause request]
(let [{:keys [body] :as response} (errors/handle cause request)]
(let [{:keys [::rres/body] :as response} (errors/handle cause request)]
(cond-> response
(map? body)
(-> (update ::rres/headers assoc "content-type" "application/transit+json")
@@ -151,9 +151,9 @@
[mw/params]
[mw/format-response]
[mw/parse-request]
[mw/errors errors/handle]
[session/soft-auth cfg]
[actoken/soft-auth cfg]
[mw/errors errors/handle]
[mw/restrict-methods]]}
(::mtx/routes cfg)

View File

@@ -57,11 +57,10 @@
(defn- serve-object
"Helper function that returns the appropriate response depending on
the storage object backend type."
[{:keys [::sto/storage] :as cfg} {:keys [backend] :as obj}]
(let [backend (sto/resolve-backend storage backend)]
(case (::sto/type backend)
:s3 (serve-object-from-s3 cfg obj)
:fs (serve-object-from-fs cfg obj))))
[cfg {:keys [backend] :as obj}]
(case backend
(:s3 :assets-s3) (serve-object-from-s3 cfg obj)
(:fs :assets-fs) (serve-object-from-fs cfg obj)))
(defn objects-handler
"Handler that servers storage objects by id."

View File

@@ -9,6 +9,7 @@
(:require
[app.common.exceptions :as ex]
[app.common.logging :as l]
[app.common.pprint :as pp]
[app.db :as db]
[app.db.sql :as sql]
[app.http.client :as http]
@@ -16,10 +17,10 @@
[app.setup :as-alias setup]
[app.tokens :as tokens]
[app.worker :as-alias wrk]
[clojure.data.json :as j]
[clojure.spec.alpha :as s]
[cuerdas.core :as str]
[integrant.core :as ig]
[jsonista.core :as j]
[promesa.exec :as px]
[ring.request :as rreq]
[ring.response :as-alias rres]))
@@ -136,83 +137,110 @@
(defn- parse-json
[v]
(ex/ignoring
(j/read-value v)))
(try
(j/read-str v)
(catch Throwable cause
(l/wrn :hint "unable to decode request body"
:cause cause))))
(defn- register-bounce-for-profile
[{:keys [::db/pool]} {:keys [type kind profile-id] :as report}]
(when (= kind "permanent")
(db/with-atomic [conn pool]
(db/insert! conn :profile-complaint-report
(try
(db/insert! pool :profile-complaint-report
{:profile-id profile-id
:type (name type)
:content (db/tjson report)})
;; TODO: maybe also try to find profiles by mail and if exists
;; register profile reports for them?
(doseq [recipient (:recipients report)]
(db/insert! conn :global-complaint-report
{:email (:email recipient)
:type (name type)
:content (db/tjson report)}))
(catch Throwable cause
(l/warn :hint "unable to persist profile complaint"
:cause cause)))
(let [profile (db/exec-one! conn (sql/select :profile {:id profile-id}))]
(when (some #(= (:email profile) (:email %)) (:recipients report))
;; If the report matches the profile email, this means that
;; the report is for itself, can be caused when a user
;; registers with an invalid email or the user email is
;; permanently rejecting receiving the email. In this case we
;; have no option to mark the user as muted (and in this case
;; the profile will be also inactive.
(db/update! conn :profile
{:is-muted true}
{:id profile-id}))))))
(defn- register-complaint-for-profile
[{:keys [::db/pool]} {:keys [type profile-id] :as report}]
(db/with-atomic [conn pool]
(db/insert! conn :profile-complaint-report
{:profile-id profile-id
:type (name type)
:content (db/tjson report)})
;; TODO: maybe also try to find profiles by email and if exists
;; register profile reports for them?
(doseq [email (:recipients report)]
(db/insert! conn :global-complaint-report
{:email email
(doseq [recipient (:recipients report)]
(db/insert! pool :global-complaint-report
{:email (:email recipient)
:type (name type)
:content (db/tjson report)}))
(let [profile (db/exec-one! conn (sql/select :profile {:id profile-id}))]
(when (some #(= % (:email profile)) (:recipients report))
(let [profile (db/exec-one! pool (sql/select :profile {:id profile-id}))]
(when (some #(= (:email profile) (:email %)) (:recipients report))
;; If the report matches the profile email, this means that
;; the report is for itself, rare case but can happen; In this
;; case just mark profile as muted (very rare case).
(db/update! conn :profile
;; the report is for itself, can be caused when a user
;; registers with an invalid email or the user email is
;; permanently rejecting receiving the email. In this case we
;; have no option to mark the user as muted (and in this case
;; the profile will be also inactive.
(l/inf :hint "mark profile: muted"
:profile-id (str (:id profile))
:email (:email profile)
:reason "bounce report"
:report-id (:feedback-id report))
(db/update! pool :profile
{:is-muted true}
{:id profile-id})))))
{:id profile-id}
{::db/return-keys false})))))
(defn- register-complaint-for-profile
[{:keys [::db/pool]} {:keys [type profile-id] :as report}]
(try
(db/insert! pool :profile-complaint-report
{:profile-id profile-id
:type (name type)
:content (db/tjson report)})
(catch Throwable cause
(l/warn :hint "unable to persist profile complaint"
:cause cause)))
;; TODO: maybe also try to find profiles by email and if exists
;; register profile reports for them?
(doseq [email (:recipients report)]
(db/insert! pool :global-complaint-report
{:email email
:type (name type)
:content (db/tjson report)}))
(let [profile (db/exec-one! pool (sql/select :profile {:id profile-id}))]
(when (some #(= % (:email profile)) (:recipients report))
;; If the report matches the profile email, this means that
;; the report is for itself, rare case but can happen; In this
;; case just mark profile as muted (very rare case).
(l/inf :hint "mark profile: muted"
:profile-id (str (:id profile))
:email (:email profile)
:reason "complaint report"
:report-id (:feedback-id report))
(db/update! pool :profile
{:is-muted true}
{:id profile-id}
{::db/return-keys false}))))
(defn- process-report
[cfg {:keys [type profile-id] :as report}]
(l/trace :action "processing report" :report (pr-str report))
(cond
;; In this case we receive a bounce/complaint notification without
;; confirmed identity, we just emit a warning but do nothing about
;; it because this is not a normal case. All notifications should
;; come with profile identity.
(nil? profile-id)
(l/warn :msg "a notification without identity received from AWS"
:report (pr-str report))
(l/wrn :hint "not-identified report"
::l/body (pp/pprint-str report {:length 40 :level 6}))
(= "bounce" type)
(register-bounce-for-profile cfg report)
(do
(l/trc :hint "bounce report"
::l/body (pp/pprint-str report {:length 40 :level 6}))
(register-bounce-for-profile cfg report))
(= "complaint" type)
(register-complaint-for-profile cfg report)
(do
(l/trc :hint "complaint report"
::l/body (pp/pprint-str report {:length 40 :level 6}))
(register-complaint-for-profile cfg report))
:else
(l/warn :msg "unrecognized report received from AWS"
:report (pr-str report))))
(l/wrn :hint "unrecognized report"
::l/body (pp/pprint-str report {:length 20 :level 4}))))

View File

@@ -54,9 +54,10 @@
"A convencience toplevel function for gradual migration to a new API
convention."
([cfg-or-client request]
(let [client (resolve-client cfg-or-client)]
(let [client (resolve-client cfg-or-client)
request (update request :uri str)]
(send! client request {:sync? true})))
([cfg-or-client request options]
(let [client (resolve-client cfg-or-client)]
(let [client (resolve-client cfg-or-client)
request (update request :uri str)]
(send! client request (merge {:sync? true} options)))))

View File

@@ -16,7 +16,6 @@
[app.config :as cf]
[app.db :as db]
[app.http.session :as session]
[app.main :as-alias main]
[app.rpc.commands.auth :as auth]
[app.rpc.commands.files-create :refer [create-file]]
[app.rpc.commands.profile :as profile]
@@ -341,57 +340,57 @@
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
(defn- resend-email-notification
[{:keys [::db/pool ::setup/props] :as cfg} {:keys [params] :as request}]
[cfg {:keys [params] :as request}]
(db/tx-run! cfg (fn [{:keys [::db/conn] :as cfg}]
(when-not (contains? params :force)
(ex/raise :type :validation
:code :missing-force
:hint "missing force checkbox"))
(when-not (contains? params :force)
(ex/raise :type :validation
:code :missing-force
:hint "missing force checkbox"))
(let [profile (some->> params
:email
(profile/clean-email)
(profile/get-profile-by-email conn))]
(let [profile (some->> params
:email
(profile/clean-email)
(profile/get-profile-by-email pool))]
(when-not profile
(ex/raise :type :validation
:code :missing-profile
:hint "unable to find profile by email"))
(when-not profile
(ex/raise :type :validation
:code :missing-profile
:hint "unable to find profile by email"))
(cond
(contains? params :block)
(do
(db/update! conn :profile {:is-blocked true} {:id (:id profile)})
(db/delete! conn :http-session {:profile-id (:id profile)})
(cond
(contains? params :block)
(do
(db/update! pool :profile {:is-blocked true} {:id (:id profile)})
(db/delete! pool :http-session {:profile-id (:id profile)})
{::rres/status 200
::rres/headers {"content-type" "text/plain"}
::rres/body (str/ffmt "PROFILE '%' BLOCKED" (:email profile))})
{::rres/status 200
::rres/headers {"content-type" "text/plain"}
::rres/body (str/ffmt "PROFILE '%' BLOCKED" (:email profile))})
(contains? params :unblock)
(do
(db/update! conn :profile {:is-blocked false} {:id (:id profile)})
{::rres/status 200
::rres/headers {"content-type" "text/plain"}
::rres/body (str/ffmt "PROFILE '%' UNBLOCKED" (:email profile))})
(contains? params :unblock)
(do
(db/update! pool :profile {:is-blocked false} {:id (:id profile)})
{::rres/status 200
::rres/headers {"content-type" "text/plain"}
::rres/body (str/ffmt "PROFILE '%' UNBLOCKED" (:email profile))})
(contains? params :resend)
(if (:is-blocked profile)
{::rres/status 200
::rres/headers {"content-type" "text/plain"}
::rres/body "PROFILE ALREADY BLOCKED"}
(do
(#'auth/send-email-verification! cfg profile)
{::rres/status 200
::rres/headers {"content-type" "text/plain"}
::rres/body (str/ffmt "RESENDED FOR '%'" (:email profile))}))
(contains? params :resend)
(if (:is-blocked profile)
{::rres/status 200
::rres/headers {"content-type" "text/plain"}
::rres/body "PROFILE ALREADY BLOCKED"}
(do
(auth/send-email-verification! pool props profile)
{::rres/status 200
::rres/headers {"content-type" "text/plain"}
::rres/body (str/ffmt "RESENDED FOR '%'" (:email profile))}))
:else
(do
(db/update! pool :profile {:is-active true} {:id (:id profile)})
{::rres/status 200
::rres/headers {"content-type" "text/plain"}
::rres/body (str/ffmt "PROFILE '%' ACTIVATED" (:email profile))}))))
:else
(do
(db/update! conn :profile {:is-active true} {:id (:id profile)})
{::rres/status 200
::rres/headers {"content-type" "text/plain"}
::rres/body (str/ffmt "PROFILE '%' ACTIVATED" (:email profile))}))))))
(defn- reset-file-version

View File

@@ -14,32 +14,28 @@
[app.http :as-alias http]
[app.http.access-token :as-alias actoken]
[app.http.session :as-alias session]
[app.util.inet :as inet]
[clojure.spec.alpha :as s]
[cuerdas.core :as str]
[ring.request :as rreq]
[ring.response :as rres]))
(defn- parse-client-ip
[request]
(or (some-> (rreq/get-header request "x-forwarded-for") (str/split ",") first)
(rreq/get-header request "x-real-ip")
(rreq/remote-addr request)))
(defn request->context
"Extracts error report relevant context data from request."
[request]
(let [claims (-> {}
(into (::session/token-claims request))
(into (::actoken/token-claims request)))]
{:request/path (:path request)
:request/method (:method request)
:request/params (:params request)
:request/user-agent (rreq/get-header request "user-agent")
:request/ip-addr (parse-client-ip request)
:request/ip-addr (inet/parse-request request)
:request/profile-id (:uid claims)
:version/frontend (or (rreq/get-header request "x-frontend-version") "unknown")
:version/backend (:full cf/version)}))
(defmulti handle-error
(fn [cause _ _]
(-> cause ex-data :type)))

View File

@@ -7,19 +7,19 @@
(ns app.http.middleware
(:require
[app.common.exceptions :as ex]
[app.common.json :as json]
[app.common.logging :as l]
[app.common.schema :as-alias sm]
[app.common.transit :as t]
[app.config :as cf]
[app.util.json :as json]
[app.http.errors :as errors]
[app.util.pointer-map :as pmap]
[cuerdas.core :as str]
[ring.request :as rreq]
[ring.response :as rres]
[yetti.adapter :as yt]
[yetti.middleware :as ymw])
(:import
com.fasterxml.jackson.core.JsonParseException
com.fasterxml.jackson.core.io.JsonEOFException
com.fasterxml.jackson.databind.exc.MismatchedInputException
io.undertow.server.RequestTooBigException
java.io.InputStream
java.io.OutputStream))
@@ -34,11 +34,12 @@
{:name ::params
:compile (constantly ymw/wrap-params)})
(def ^:private json-mapper
(json/mapper
{:encode-key-fn str/camel
:decode-key-fn (comp keyword str/kebab)
:pretty true}))
(defn- get-reader
^java.io.BufferedReader
[request]
(let [^InputStream body (rreq/body request)]
(java.io.BufferedReader.
(java.io.InputStreamReader. body))))
(defn wrap-parse-request
[handler]
@@ -53,8 +54,8 @@
(update :params merge params))))
(str/starts-with? header "application/json")
(with-open [^InputStream is (rreq/body request)]
(let [params (json/decode is json-mapper)]
(with-open [reader (get-reader request)]
(let [params (json/read reader :key-fn json/read-kebab-key)]
(-> request
(assoc :body-params params)
(update :params merge params))))
@@ -62,35 +63,33 @@
:else
request)))
(handle-error [cause]
(handle-error [cause request]
(cond
(instance? RuntimeException cause)
(if-let [cause (ex-cause cause)]
(handle-error cause)
(throw cause))
(handle-error cause request)
(errors/handle cause request))
(instance? RequestTooBigException cause)
(ex/raise :type :validation
:code :request-body-too-large
:hint (ex-message cause))
(or (instance? JsonEOFException cause)
(instance? JsonParseException cause)
(instance? MismatchedInputException cause))
(instance? java.io.EOFException cause)
(ex/raise :type :validation
:code :malformed-json
:hint (ex-message cause)
:cause cause)
:else
(throw cause)))]
(errors/handle cause request)))]
(fn [request]
(if (= (rreq/method request) :post)
(let [request (ex/try! (process-request request))]
(if (ex/exception? request)
(handle-error request)
(handler request)))
(try
(-> request process-request handler)
(catch Throwable cause
(handle-error cause request)))
(handler request)))))
(def parse-request
@@ -106,6 +105,12 @@
(def ^:const buffer-size (:xnio/buffer-size yt/defaults))
(defn- write-json-value
[_ val]
(if (pmap/pointer-map? val)
[(pmap/get-id val) (meta val)]
val))
(defn wrap-format-response
[handler]
(letfn [(transit-streamable-body [data opts]
@@ -127,9 +132,11 @@
(reify rres/StreamableResponseBody
(-write-body-to-stream [_ _ output-stream]
(try
(with-open [^OutputStream bos (buffered-output-stream output-stream buffer-size)]
(json/write! bos data json-mapper))
(let [encode (or (-> data meta :encode/json) identity)
data (encode data)]
(with-open [^OutputStream bos (buffered-output-stream output-stream buffer-size)]
(with-open [^java.io.OutputStreamWriter writer (java.io.OutputStreamWriter. bos)]
(json/write writer data :key-fn json/write-camel-key :value-fn write-json-value))))
(catch java.io.IOException _)
(catch Throwable cause
(binding [l/*context* {:value data}]

View File

@@ -10,6 +10,7 @@
[app.common.data :as d]
[app.common.logging :as l]
[app.common.spec :as us]
[app.common.uri :as u]
[app.config :as cf]
[app.db :as db]
[app.db.sql :as sql]
@@ -33,7 +34,7 @@
;; A cookie that we can use to check from other sites of the same
;; domain if a user is authenticated.
(def default-authenticated-cookie-name "authenticated")
(def default-auth-data-cookie-name "auth-data")
;; Default value for cookie max-age
(def default-cookie-max-age (dt/duration {:days 7}))
@@ -133,9 +134,9 @@
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
(declare ^:private assign-auth-token-cookie)
(declare ^:private assign-authenticated-cookie)
(declare ^:private assign-auth-data-cookie)
(declare ^:private clear-auth-token-cookie)
(declare ^:private clear-authenticated-cookie)
(declare ^:private clear-auth-data-cookie)
(declare ^:private gen-token)
(defn create-fn
@@ -153,7 +154,7 @@
(l/trace :hint "create" :profile-id (str profile-id))
(-> response
(assign-auth-token-cookie session)
(assign-authenticated-cookie session)))))
(assign-auth-data-cookie session)))))
(defn delete-fn
[{:keys [::manager]}]
@@ -167,7 +168,7 @@
(assoc :status 204)
(assoc :body nil)
(clear-auth-token-cookie)
(clear-authenticated-cookie)))))
(clear-auth-data-cookie)))))
(defn- gen-token
[props {:keys [profile-id created-at]}]
@@ -229,7 +230,7 @@
(let [session (update! manager session)]
(-> response
(assign-auth-token-cookie session)
(assign-authenticated-cookie session)))
(assign-auth-data-cookie session)))
response))))
(def soft-auth
@@ -262,11 +263,11 @@
:secure secure?}]
(update response :cookies assoc name cookie)))
(defn- assign-authenticated-cookie
[response {updated-at :updated-at}]
(defn- assign-auth-data-cookie
[response {profile-id :profile-id updated-at :updated-at}]
(let [max-age (cf/get :auth-token-cookie-max-age default-cookie-max-age)
domain (cf/get :authenticated-cookie-domain)
cname (cf/get :authenticated-cookie-name "authenticated")
domain (cf/get :auth-data-cookie-domain)
cname default-auth-data-cookie-name
created-at (or updated-at (dt/now))
renewal (dt/plus created-at default-renewal-max-age)
@@ -274,14 +275,17 @@
comment (str "Renewal at: " (dt/format-instant renewal :rfc1123))
secure? (contains? cf/flags :secure-session-cookies)
strict? (contains? cf/flags :strict-session-cookies)
cors? (contains? cf/flags :cors)
cookie {:domain domain
:expires expires
:path "/"
:comment comment
:value true
:same-site :strict
:value (u/map->query-string {:profile-id profile-id})
:same-site (if cors? :none (if strict? :strict :lax))
:secure secure?}]
(cond-> response
(string? domain)
(update :cookies assoc cname cookie))))
@@ -291,10 +295,10 @@
(let [cname (cf/get :auth-token-cookie-name default-auth-token-cookie-name)]
(update response :cookies assoc cname {:path "/" :value "" :max-age 0})))
(defn- clear-authenticated-cookie
(defn- clear-auth-data-cookie
[response]
(let [cname (cf/get :authenticated-cookie-name default-authenticated-cookie-name)
domain (cf/get :authenticated-cookie-domain)]
(let [cname default-auth-data-cookie-name
domain (cf/get :auth-data-cookie-domain)]
(cond-> response
(string? domain)
(update :cookies assoc cname {:domain domain :path "/" :value "" :max-age 0}))))

View File

@@ -61,6 +61,8 @@
(let [result (handler)]
(events/tap :end result))
(catch Throwable cause
(l/err :hint "unexpected error on processing sse response"
:cause cause)
(events/tap :error (errors/handle' cause request)))
(finally
(sp/close! events/*channel*)

View File

@@ -21,24 +21,18 @@
[app.rpc :as-alias rpc]
[app.rpc.retry :as rtry]
[app.setup :as-alias setup]
[app.util.inet :as inet]
[app.util.services :as-alias sv]
[app.util.time :as dt]
[app.worker :as wrk]
[clojure.spec.alpha :as s]
[cuerdas.core :as str]
[integrant.core :as ig]
[ring.request :as rreq]))
[integrant.core :as ig]))
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;; HELPERS
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
(defn parse-client-ip
[request]
(or (some-> (rreq/get-header request "x-forwarded-for") (str/split ",") first)
(rreq/get-header request "x-real-ip")
(some-> (rreq/remote-addr request) str)))
(defn extract-utm-params
"Extracts additional data from params and namespace them under
`penpot` ns."
@@ -53,8 +47,7 @@
(assoc (->> sk str/kebab (keyword "penpot")) v))))]
(reduce-kv process-param {} params)))
(def ^:private
profile-props
(def profile-props
[:id
:is-active
:is-muted
@@ -87,8 +80,19 @@
(remove #(contains? reserved-props (key %))))
props))
;; --- SPECS
(defn event-from-rpc-params
"Create a base event skeleton with pre-filled some important
data that can be extracted from RPC params object"
[params]
(let [context {:external-session-id (::rpc/external-session-id params)
:external-event-origin (::rpc/external-event-origin params)
:triggered-by (::rpc/handler-name params)}]
{::type "action"
::profile-id (::rpc/profile-id params)
::ip-addr (::rpc/ip-addr params)
::context (d/without-nils context)}))
;; --- SPECS
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;; COLLECTOR
@@ -141,24 +145,31 @@
(::rpc/profile-id params)
uuid/zero)
props (-> (or (::replace-props resultm)
(-> params
(merge (::props resultm))
(dissoc :profile-id)
(dissoc :type)))
session-id (get params ::rpc/external-session-id)
event-origin (get params ::rpc/external-event-origin)
props (-> (or (::replace-props resultm)
(-> params
(merge (::props resultm))
(dissoc :profile-id)
(dissoc :type)))
(clean-props))
(clean-props))
token-id (::actoken/id request)
context (d/without-nils
{:access-token-id (some-> token-id str)})]
context (-> (::context resultm)
(assoc :external-session-id session-id)
(assoc :external-event-origin event-origin)
(assoc :access-token-id (some-> token-id str))
(d/without-nils))
ip-addr (inet/parse-request request)]
{::type (or (::type resultm)
(::rpc/type cfg))
::name (or (::name resultm)
(::sv/name mdata))
::profile-id profile-id
::ip-addr (some-> request parse-client-ip)
::ip-addr ip-addr
::props props
::context context
@@ -180,15 +191,33 @@
(::webhooks/event? resultm)
false)}))
(defn- handle-event!
[cfg event]
(defn- event->params
[event]
(let [params {:id (uuid/next)
:name (::name event)
:type (::type event)
:profile-id (::profile-id event)
:ip-addr (::ip-addr event)
:context (::context event)
:props (::props event)}
:context (::context event {})
:props (::props event {})
:source "backend"}
tnow (::tracked-at event)]
(cond-> params
(some? tnow)
(assoc :tracked-at tnow))))
(defn- append-audit-entry!
[cfg params]
(let [params (-> params
(update :props db/tjson)
(update :context db/tjson)
(update :ip-addr db/inet))]
(db/insert! cfg :audit-log params)))
(defn- handle-event!
[cfg event]
(let [params (event->params event)
tnow (dt/now)]
(when (contains? cf/flags :audit-log)
@@ -197,12 +226,8 @@
;; this case we just retry the operation.
(let [params (-> params
(assoc :created-at tnow)
(assoc :tracked-at tnow)
(update :props db/tjson)
(update :context db/tjson)
(update :ip-addr db/inet)
(assoc :source "backend"))]
(db/insert! cfg :audit-log params)))
(update :tracked-at #(or % tnow)))]
(append-audit-entry! cfg params)))
(when (and (or (contains? cf/flags :telemetry)
(cf/get :telemetry-enabled))
@@ -214,12 +239,10 @@
;; NOTE: this is only executed when general audit log is disabled
(let [params (-> params
(assoc :created-at tnow)
(assoc :tracked-at tnow)
(assoc :props (db/tjson {}))
(assoc :context (db/tjson {}))
(assoc :ip-addr (db/inet "0.0.0.0"))
(assoc :source "backend"))]
(db/insert! cfg :audit-log params)))
(update :tracked-at #(or % tnow))
(assoc :props {})
(assoc :context {}))]
(append-audit-entry! cfg params)))
(when (and (contains? cf/flags :webhooks)
(::webhooks/event? event))
@@ -232,25 +255,25 @@
:else label)
dedupe? (boolean (and batch-key batch-timeout))]
(wrk/submit! ::wrk/conn (::db/conn cfg)
::wrk/task :process-webhook-event
::wrk/queue :webhooks
::wrk/max-retries 0
::wrk/delay (or batch-timeout 0)
::wrk/dedupe dedupe?
::wrk/label label
::webhooks/event
(-> params
(dissoc :ip-addr)
(dissoc :type)))))
(wrk/submit! (-> cfg
(assoc ::wrk/task :process-webhook-event)
(assoc ::wrk/queue :webhooks)
(assoc ::wrk/max-retries 0)
(assoc ::wrk/delay (or batch-timeout 0))
(assoc ::wrk/dedupe dedupe?)
(assoc ::wrk/label label)
(assoc ::wrk/params (-> params
(dissoc :source)
(dissoc :context)
(dissoc :ip-addr)
(dissoc :type)))))))
params))
(defn submit!
"Submit audit event to the collector."
[cfg params]
[cfg event]
(try
(let [event (d/without-nils params)
(let [event (d/without-nils event)
cfg (-> cfg
(assoc ::rtry/when rtry/conflict-exception?)
(assoc ::rtry/max-retries 6)
@@ -259,3 +282,18 @@
(rtry/invoke! cfg db/tx-run! handle-event! event))
(catch Throwable cause
(l/error :hint "unexpected error processing event" :cause cause))))
(defn insert!
"Submit audit event to the collector, intended to be used only from
command line helpers because this skips all webhooks and telemetry
logic."
[cfg event]
(when (contains? cf/flags :audit-log)
(let [event (d/without-nils event)]
(us/verify! ::event event)
(db/run! cfg (fn [cfg]
(let [tnow (dt/now)
params (-> (event->params event)
(assoc :created-at tnow)
(update :tracked-at #(or % tnow)))]
(append-audit-entry! cfg params)))))))

View File

@@ -64,23 +64,20 @@
(s/keys :req [::db/pool]))
(defmethod ig/init-key ::process-event-handler
[_ {:keys [::db/pool] :as cfg}]
[_ cfg]
(fn [{:keys [props] :as task}]
(let [event (::event props)]
(l/dbg :hint "process webhook event" :name (:name event))
(when-let [items (lookup-webhooks cfg event)]
(l/trc :hint "webhooks found for event" :total (count items))
(db/with-atomic [conn pool]
(doseq [item items]
(wrk/submit! ::wrk/conn conn
::wrk/task :run-webhook
::wrk/queue :webhooks
::wrk/max-retries 3
::event event
::config item)))))))
(l/dbg :hint "process webhook event" :name (:name props))
(when-let [items (lookup-webhooks cfg props)]
(l/trc :hint "webhooks found for event" :total (count items))
(db/tx-run! cfg (fn [cfg]
(doseq [item items]
(wrk/submit! (-> cfg
(assoc ::wrk/task :run-webhook)
(assoc ::wrk/queue :webhooks)
(assoc ::wrk/max-retries 3)
(assoc ::wrk/params {:event props
:config item})))))))))
;; --- RUN
(declare interpret-exception)
@@ -128,8 +125,8 @@
:rsp-data (db/tjson rsp)}))]
(fn [{:keys [props] :as task}]
(let [event (::event props)
whook (::config props)
(let [event (:event props)
whook (:config props)
body (case (:mtype whook)
"application/json" (json/write-str event json-write-opts)

View File

@@ -102,13 +102,13 @@
{::mdef/name "penpot_tasks_timing"
::mdef/help "Background tasks timing (milliseconds)."
::mdef/labels ["name"]
::mdef/type :summary}
::mdef/type :histogram}
:redis-eval-timing
{::mdef/name "penpot_redis_eval_timing"
::mdef/help "Redis EVAL commands execution timings (ms)"
::mdef/labels ["name"]
::mdef/type :summary}
::mdef/type :histogram}
:rpc-climit-queue
{::mdef/name "penpot_rpc_climit_queue"
@@ -126,7 +126,7 @@
{::mdef/name "penpot_rpc_climit_timing"
::mdef/help "Summary of the time between queuing and executing on the CLIMIT"
::mdef/labels ["name"]
::mdef/type :summary}
::mdef/type :histogram}
:audit-http-handler-queue-size
{::mdef/name "penpot_audit_http_handler_queue_size"
@@ -144,7 +144,7 @@
{::mdef/name "penpot_audit_http_handler_timing"
::mdef/help "Summary of the time between queuing and executing on the audit log http handler"
::mdef/labels []
::mdef/type :summary}
::mdef/type :histogram}
:executors-active-threads
{::mdef/name "penpot_executors_active_threads"
@@ -254,7 +254,7 @@
{::http.client/client (ig/ref ::http.client/client)}
::oidc.providers/gitlab
{}
{::http.client/client (ig/ref ::http.client/client)}
::oidc.providers/generic
{::http.client/client (ig/ref ::http.client/client)}
@@ -267,7 +267,9 @@
:github (ig/ref ::oidc.providers/github)
:gitlab (ig/ref ::oidc.providers/gitlab)
:oidc (ig/ref ::oidc.providers/generic)}
::session/manager (ig/ref ::session/manager)}
::session/manager (ig/ref ::session/manager)
::email/blacklist (ig/ref ::email/blacklist)
::email/whitelist (ig/ref ::email/whitelist)}
:app.http/router
{::session/manager (ig/ref ::session/manager)
@@ -322,7 +324,10 @@
::rpc/climit (ig/ref ::rpc/climit)
::rpc/rlimit (ig/ref ::rpc/rlimit)
::setup/templates (ig/ref ::setup/templates)
::setup/props (ig/ref ::setup/props)}
::setup/props (ig/ref ::setup/props)
::email/blacklist (ig/ref ::email/blacklist)
::email/whitelist (ig/ref ::email/whitelist)}
:app.rpc.doc/routes
{:methods (ig/ref :app.rpc/methods)}
@@ -338,8 +343,9 @@
::wrk/tasks
{:sendmail (ig/ref ::email/handler)
:objects-gc (ig/ref :app.tasks.objects-gc/handler)
:orphan-teams-gc (ig/ref :app.tasks.orphan-teams-gc/handler)
:file-gc (ig/ref :app.tasks.file-gc/handler)
:file-gc-scheduler (ig/ref :app.tasks.file-gc-scheduler/handler)
:offload-file-data (ig/ref :app.tasks.offload-file-data/handler)
:file-xlog-gc (ig/ref :app.tasks.file-xlog-gc/handler)
:tasks-gc (ig/ref :app.tasks.tasks-gc/handler)
:telemetry (ig/ref :app.tasks.telemetry/handler)
@@ -349,11 +355,19 @@
:audit-log-archive (ig/ref :app.loggers.audit.archive-task/handler)
:audit-log-gc (ig/ref :app.loggers.audit.gc-task/handler)
:delete-object
(ig/ref :app.tasks.delete-object/handler)
:process-webhook-event
(ig/ref ::webhooks/process-event-handler)
:run-webhook
(ig/ref ::webhooks/run-webhook-handler)}}
::email/blacklist
{}
::email/whitelist
{}
::email/sendmail
{::email/host (cf/get :smtp-host)
::email/port (cf/get :smtp-port)
@@ -375,16 +389,24 @@
{::db/pool (ig/ref ::db/pool)
::sto/storage (ig/ref ::sto/storage)}
:app.tasks.orphan-teams-gc/handler
{::db/pool (ig/ref ::db/pool)}
:app.tasks.delete-object/handler
{::db/pool (ig/ref ::db/pool)}
:app.tasks.file-gc/handler
{::db/pool (ig/ref ::db/pool)
::sto/storage (ig/ref ::sto/storage)}
:app.tasks.file-xlog-gc/handler
:app.tasks.file-gc-scheduler/handler
{::db/pool (ig/ref ::db/pool)}
:app.tasks.offload-file-data/handler
{::db/pool (ig/ref ::db/pool)
::sto/storage (ig/ref ::sto/storage)}
:app.tasks.file-xlog-gc/handler
{::db/pool (ig/ref ::db/pool)
::sto/storage (ig/ref ::sto/storage)}
:app.tasks.telemetry/handler
{::db/pool (ig/ref ::db/pool)
::http.client/client (ig/ref ::http.client/client)
@@ -436,17 +458,28 @@
::sto/storage
{::db/pool (ig/ref ::db/pool)
::sto/backends
{:assets-s3 (ig/ref [::assets :app.storage.s3/backend])
:assets-fs (ig/ref [::assets :app.storage.fs/backend])}}
{:s3 (ig/ref :app.storage.s3/backend)
:fs (ig/ref :app.storage.fs/backend)
[::assets :app.storage.s3/backend]
{::sto.s3/region (cf/get :storage-assets-s3-region)
::sto.s3/endpoint (cf/get :storage-assets-s3-endpoint)
::sto.s3/bucket (cf/get :storage-assets-s3-bucket)
::sto.s3/io-threads (cf/get :storage-assets-s3-io-threads)}
;; LEGACY (should not be removed, can only be removed after an
;; explicit migration because the database objects/rows will
;; still reference the old names).
:assets-s3 (ig/ref :app.storage.s3/backend)
:assets-fs (ig/ref :app.storage.fs/backend)}}
[::assets :app.storage.fs/backend]
{::sto.fs/directory (cf/get :storage-assets-fs-directory)}})
:app.storage.s3/backend
{::sto.s3/region (or (cf/get :storage-assets-s3-region)
(cf/get :objects-storage-s3-region))
::sto.s3/endpoint (or (cf/get :storage-assets-s3-endpoint)
(cf/get :objects-storage-s3-endpoint))
::sto.s3/bucket (or (cf/get :storage-assets-s3-bucket)
(cf/get :objects-storage-s3-bucket))
::sto.s3/io-threads (or (cf/get :storage-assets-s3-io-threads)
(cf/get :objects-storage-s3-io-threads))}
:app.storage.fs/backend
{::sto.fs/directory (or (cf/get :storage-assets-fs-directory)
(cf/get :objects-storage-fs-directory))}})
(def worker-config
@@ -463,9 +496,6 @@
{:cron #app/cron "0 0 0 * * ?" ;; daily
:task :objects-gc}
{:cron #app/cron "0 0 0 * * ?" ;; daily
:task :orphan-teams-gc}
{:cron #app/cron "0 0 0 * * ?" ;; daily
:task :storage-gc-deleted}
@@ -476,7 +506,7 @@
:task :tasks-gc}
{:cron #app/cron "0 0 2 * * ?" ;; daily
:task :file-gc}
:task :file-gc-scheduler}
{:cron #app/cron "0 30 */3,23 * * ?"
:task :telemetry}
@@ -515,6 +545,7 @@
(defn start
[]
(cf/validate!)
(ig/load-namespaces (merge system-config worker-config))
(alter-var-root #'system (fn [sys]
(when sys (ig/halt! sys))

View File

@@ -11,7 +11,6 @@
[app.common.exceptions :as ex]
[app.common.media :as cm]
[app.common.schema :as sm]
[app.common.schema.generators :as sg]
[app.common.schema.openapi :as-alias oapi]
[app.common.spec :as us]
[app.common.svg :as csvg]
@@ -47,22 +46,10 @@
(s/keys :req-un [::path]
:opt-un [::mtype]))
(sm/def! ::fs/path
{:type ::fs/path
:pred fs/path?
:type-properties
{:title "path"
:description "filesystem path"
:error/message "expected a valid fs path instance"
:gen/gen (sg/generator :string)
::oapi/type "string"
::oapi/format "unix-path"
::oapi/decode fs/path}})
(sm/def! ::upload
(sm/register! ::upload
[:map {:title "Upload"}
[:filename :string]
[:size :int]
[:size ::sm/int]
[:path ::fs/path]
[:mtype {:optional true} :string]
[:headers {:optional true}
@@ -326,17 +313,3 @@
(= stype :ttf)
(-> (assoc "font/otf" (ttf->otf sfnt))
(assoc "font/ttf" sfnt)))))))))
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;; Utility functions
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
(defn configure-assets-storage
"Given storage map, returns a storage configured with the appropriate
backend for assets and optional connection attached."
([storage]
(assoc storage ::sto/backend (cf/get :assets-storage-backend :assets-fs)))
([storage pool-or-conn]
(-> (configure-assets-storage storage)
(assoc ::db/pool-or-conn pool-or-conn))))

View File

@@ -379,7 +379,40 @@
:fn (mg/resource "app/migrations/sql/0119-mod-file-table.sql")}
{:name "0120-mod-audit-log-table"
:fn (mg/resource "app/migrations/sql/0120-mod-audit-log-table.sql")}])
:fn (mg/resource "app/migrations/sql/0120-mod-audit-log-table.sql")}
{:name "0121-mod-file-data-fragment-table"
:fn (mg/resource "app/migrations/sql/0121-mod-file-data-fragment-table.sql")}
{:name "0122-mod-file-table"
:fn (mg/resource "app/migrations/sql/0122-mod-file-table.sql")}
{:name "0122-mod-file-data-fragment-table"
:fn (mg/resource "app/migrations/sql/0122-mod-file-data-fragment-table.sql")}
{:name "0123-mod-file-change-table"
:fn (mg/resource "app/migrations/sql/0123-mod-file-change-table.sql")}
{:name "0124-mod-profile-table"
:fn (mg/resource "app/migrations/sql/0124-mod-profile-table.sql")}
{:name "0125-mod-file-table"
:fn (mg/resource "app/migrations/sql/0125-mod-file-table.sql")}
{:name "0126-add-team-access-request-table"
:fn (mg/resource "app/migrations/sql/0126-add-team-access-request-table.sql")}
{:name "0127-mod-storage-object-table"
:fn (mg/resource "app/migrations/sql/0127-mod-storage-object-table.sql")}
{:name "0128-mod-task-table"
:fn (mg/resource "app/migrations/sql/0128-mod-task-table.sql")}
{:name "0129-mod-file-change-table"
:fn (mg/resource "app/migrations/sql/0129-mod-file-change-table.sql")}
{:name "0130-mod-file-change-table"
:fn (mg/resource "app/migrations/sql/0130-mod-file-change-table.sql")}])
(defn apply-migrations!
[pool name migrations]

View File

@@ -0,0 +1,8 @@
ALTER TABLE file_data_fragment
ADD COLUMN data bytea NULL;
UPDATE file_data_fragment
SET data = content;
ALTER TABLE file_data_fragment
DROP COLUMN content;

View File

@@ -0,0 +1,6 @@
ALTER TABLE file_data_fragment
ADD COLUMN data_backend text NULL,
ADD COLUMN data_ref_id uuid NULL;
CREATE INDEX IF NOT EXISTS file_data_fragment__data_ref_id__idx
ON file_data_fragment (data_ref_id);

View File

@@ -0,0 +1,6 @@
ALTER TABLE file_data_fragment
ADD COLUMN data_backend text NULL,
ADD COLUMN data_ref_id uuid NULL;
CREATE INDEX IF NOT EXISTS file_data_fragment__data_ref_id__idx
ON file_data_fragment (data_ref_id);

View File

@@ -0,0 +1,4 @@
ALTER TABLE file ADD COLUMN data_ref_id uuid NULL;
CREATE INDEX IF NOT EXISTS file__data_ref_id__idx
ON file (data_ref_id);

View File

@@ -0,0 +1,2 @@
CREATE INDEX IF NOT EXISTS file_change__created_at__label__idx
ON file_change (created_at, label);

View File

@@ -0,0 +1,2 @@
CREATE INDEX profile__props__newsletter1__idx ON profile (email) WHERE props->>'~:newsletter-news' = 'true';
CREATE INDEX profile__props__newsletter2__idx ON profile (email) WHERE props->>'~:newsletter-updates' = 'true';

View File

@@ -0,0 +1,3 @@
--- This setting allow to optimize the table for heavy write workload
--- leaving space on the page for HOT updates
ALTER TABLE file SET (FILLFACTOR=50);

View File

@@ -0,0 +1,10 @@
CREATE TABLE team_access_request (
id uuid PRIMARY KEY DEFAULT uuid_generate_v4(),
team_id uuid NOT NULL REFERENCES team(id) ON DELETE CASCADE DEFERRABLE,
requester_id uuid NULL REFERENCES profile(id) ON DELETE CASCADE DEFERRABLE,
valid_until timestamptz NOT NULL,
auto_join_until timestamptz NOT NULL,
created_at timestamptz NOT NULL DEFAULT now(),
updated_at timestamptz NOT NULL DEFAULT now(),
UNIQUE (team_id, requester_id)
);

View File

@@ -0,0 +1,3 @@
--- This setting allow to optimize the table for heavy write workload
--- leaving space on the page for HOT updates
ALTER TABLE storage_object SET (FILLFACTOR=60);

View File

@@ -0,0 +1,3 @@
--- This setting allow to optimize the table for heavy write workload
--- leaving space on the page for HOT updates
ALTER TABLE task SET (FILLFACTOR=60);

View File

@@ -0,0 +1,6 @@
ALTER TABLE file_change
ADD COLUMN data_backend text NULL,
ADD COLUMN data_ref_id uuid NULL;
CREATE INDEX IF NOT EXISTS file_change__data_ref_id__idx
ON file_change (data_ref_id);

View File

@@ -0,0 +1,2 @@
ALTER TABLE file_change
ADD COLUMN version integer NULL;

View File

@@ -29,6 +29,7 @@
[app.rpc.rlimit :as rlimit]
[app.setup :as-alias setup]
[app.storage :as-alias sto]
[app.util.inet :as inet]
[app.util.services :as sv]
[app.util.time :as dt]
[clojure.spec.alpha :as s]
@@ -70,6 +71,22 @@
(handle-response-transformation request mdata)
(handle-before-comple-hook mdata))))
(defn get-external-session-id
[request]
(when-let [session-id (rreq/get-header request "x-external-session-id")]
(when-not (or (> (count session-id) 256)
(= session-id "null")
(str/blank? session-id))
session-id)))
(defn- get-external-event-origin
[request]
(when-let [origin (rreq/get-header request "x-event-origin")]
(when-not (or (> (count origin) 256)
(= origin "null")
(str/blank? origin))
origin)))
(defn- rpc-handler
"Ring handler that dispatches cmd requests and convert between
internal async flow into ring async flow."
@@ -79,8 +96,16 @@
profile-id (or (::session/profile-id request)
(::actoken/profile-id request))
ip-addr (inet/parse-request request)
session-id (get-external-session-id request)
event-origin (get-external-event-origin request)
data (-> params
(assoc ::handler-name handler-name)
(assoc ::ip-addr ip-addr)
(assoc ::request-at (dt/now))
(assoc ::external-session-id session-id)
(assoc ::external-event-origin event-origin)
(assoc ::session/id (::session/id request))
(assoc ::cond/key etag)
(cond-> (uuid? profile-id)
@@ -153,49 +178,31 @@
(if-let [schema (::sm/params mdata)]
(let [validate (sm/validator schema)
explain (sm/explainer schema)
decode (sm/decoder schema)]
decode (sm/decoder schema sm/json-transformer)
encode (sm/encoder schema sm/json-transformer)]
(fn [cfg params]
(let [params (decode params)]
(if (validate params)
(f cfg params)
(let [result (f cfg params)]
(if (instance? clojure.lang.IObj result)
(vary-meta result assoc :encode/json encode)
result))
(let [params (d/without-qualified params)]
(ex/raise :type :validation
:code :params-validation
::sm/explain (explain params)))))))
f))
(defn- wrap-output-validation
[_ f mdata]
(if (contains? cf/flags :rpc-output-validation)
(or (when-let [schema (::sm/result mdata)]
(let [schema (if (sm/lazy-schema? schema)
schema
(sm/define schema))
validate (sm/validator schema)
explain (sm/explainer schema)]
(fn [cfg params]
(let [response (f cfg params)]
(when (map? response)
(when-not (validate response)
(ex/raise :type :validation
:code :data-validation
::sm/explain (explain response))))
response))))
f)
f))
(defn- wrap-all
[cfg f mdata]
(as-> f $
(wrap-metrics cfg $ mdata)
(cond/wrap cfg $ mdata)
(retry/wrap-retry cfg $ mdata)
(climit/wrap cfg $ mdata)
(wrap-metrics cfg $ mdata)
(rlimit/wrap cfg $ mdata)
(wrap-audit cfg $ mdata)
(wrap-spec-conform cfg $ mdata)
(wrap-output-validation cfg $ mdata)
(wrap-params-validation cfg $ mdata)
(wrap-authentication cfg $ mdata)))

View File

@@ -6,7 +6,7 @@
(ns app.rpc.commands.access-token
(:require
[app.common.spec :as us]
[app.common.schema :as sm]
[app.common.uuid :as uuid]
[app.db :as db]
[app.main :as-alias main]
@@ -16,8 +16,7 @@
[app.setup :as-alias setup]
[app.tokens :as tokens]
[app.util.services :as sv]
[app.util.time :as dt]
[clojure.spec.alpha :as s]))
[app.util.time :as dt]))
(defn- decode-row
[row]
@@ -44,7 +43,7 @@
:perms (db/create-array conn "text" [])})))
(defn repl-create-access-token
(defn repl:create-access-token
[{:keys [::db/pool] :as system} profile-id name expiration]
(db/with-atomic [conn pool]
(let [props (:app.setup/props system)]
@@ -53,16 +52,14 @@
name
expiration))))
(s/def ::name ::us/not-empty-string)
(s/def ::expiration ::dt/duration)
(s/def ::create-access-token
(s/keys :req [::rpc/profile-id]
:req-un [::name]
:opt-un [::expiration]))
(def ^:private schema:create-access-token
[:map {:title "create-access-token"}
[:name [:string {:max 250 :min 1}]]
[:expiration {:optional true} ::dt/duration]])
(sv/defmethod ::create-access-token
{::doc/added "1.18"}
{::doc/added "1.18"
::sm/params schema:create-access-token}
[{:keys [::db/pool] :as cfg} {:keys [::rpc/profile-id name expiration]}]
(db/with-atomic [conn pool]
(let [cfg (assoc cfg ::db/conn conn)]
@@ -72,21 +69,23 @@
(-> (create-access-token cfg profile-id name expiration)
(decode-row)))))
(s/def ::delete-access-token
(s/keys :req [::rpc/profile-id]
:req-un [::us/id]))
(def ^:private schema:delete-access-token
[:map {:title "delete-access-token"}
[:id ::sm/uuid]])
(sv/defmethod ::delete-access-token
{::doc/added "1.18"}
{::doc/added "1.18"
::sm/params schema:delete-access-token}
[{:keys [::db/pool]} {:keys [::rpc/profile-id id]}]
(db/delete! pool :access-token {:id id :profile-id profile-id})
nil)
(s/def ::get-access-tokens
(s/keys :req [::rpc/profile-id]))
(def ^:private schema:get-access-tokens
[:map {:title "get-access-tokens"}])
(sv/defmethod ::get-access-tokens
{::doc/added "1.18"}
{::doc/added "1.18"
::sm/params schema:get-access-tokens}
[{:keys [::db/pool]} {:keys [::rpc/profile-id]}]
(->> (db/query pool :access-token
{:profile-id profile-id}

View File

@@ -14,11 +14,12 @@
[app.config :as cf]
[app.db :as db]
[app.http :as-alias http]
[app.loggers.audit :as audit]
[app.loggers.audit :as-alias audit]
[app.rpc :as-alias rpc]
[app.rpc.climit :as-alias climit]
[app.rpc.doc :as-alias doc]
[app.rpc.helpers :as rph]
[app.util.inet :as inet]
[app.util.services :as sv]
[app.util.time :as dt]))
@@ -61,7 +62,7 @@
(defn- handle-events
[{:keys [::db/pool]} {:keys [::rpc/profile-id events] :as params}]
(let [request (-> params meta ::http/request)
ip-addr (audit/parse-client-ip request)
ip-addr (inet/parse-request request)
tnow (dt/now)
xform (comp
(map (fn [event]
@@ -77,10 +78,19 @@
(when (seq events)
(db/insert-many! pool :audit-log event-columns events))))
(def valid-event-types
#{"action" "identify"})
(def schema:event
[:map {:title "Event"}
[:name [:string {:max 250}]]
[:type [:string {:max 250}]]
[:name
[:and {:gen/elements ["update-file", "get-profile"]}
[:string {:max 250}]
[:re #"[\d\w-]{1,50}"]]]
[:type
[:and {:gen/elements valid-event-types}
[:string {:max 250}]
[::sm/one-of {:format "string"} valid-event-types]]]
[:props
[:map-of :keyword :any]]
[:context {:optional true}

View File

@@ -6,7 +6,6 @@
(ns app.rpc.commands.auth
(:require
[app.auth :as auth]
[app.common.data :as d]
[app.common.data.macros :as dm]
[app.common.exceptions :as ex]
@@ -17,9 +16,10 @@
[app.config :as cf]
[app.db :as db]
[app.email :as eml]
[app.email.blacklist :as email.blacklist]
[app.email.whitelist :as email.whitelist]
[app.http.session :as session]
[app.loggers.audit :as audit]
[app.main :as-alias main]
[app.rpc :as-alias rpc]
[app.rpc.climit :as-alias climit]
[app.rpc.commands.profile :as profile]
@@ -27,9 +27,11 @@
[app.rpc.doc :as-alias doc]
[app.rpc.helpers :as rph]
[app.setup :as-alias setup]
[app.setup.welcome-file :refer [create-welcome-file]]
[app.tokens :as tokens]
[app.util.services :as sv]
[app.util.time :as dt]
[app.worker :as wrk]
[cuerdas.core :as str]))
(def schema:password
@@ -38,6 +40,12 @@
(def schema:token
[::sm/word-string {:max 6000}])
(defn- elapsed-verify-threshold?
[profile]
(let [elapsed (dt/diff (:modified-at profile) (dt/now))
verify-threshold (cf/get :email-verify-threshold)]
(pos? (compare elapsed verify-threshold))))
;; ---- COMMAND: login with password
(defn login-with-password
@@ -122,12 +130,21 @@
;; ---- COMMAND: Logout
(def ^:private schema:logout
[:map {:title "logoug"}
[:profile-id {:optional true} ::sm/uuid]])
(sv/defmethod ::logout
"Clears the authentication cookie and logout the current session."
{::rpc/auth false
::doc/added "1.15"}
[cfg _]
(rph/with-transform {} (session/delete-fn cfg)))
::doc/changes [["2.1" "Now requires profile-id passed in the body"]]
::doc/added "1.0"
::sm/params schema:logout}
[cfg params]
(if (= (:profile-id params)
(::rpc/profile-id params))
(rph/with-transform {} (session/delete-fn cfg))
{}))
;; ---- COMMAND: Recover Profile
@@ -139,7 +156,7 @@
(update-password [conn profile-id]
(let [pwd (profile/derive-password cfg password)]
(db/update! conn :profile {:password pwd} {:id profile-id})
(db/update! conn :profile {:password pwd :is-active true} {:id profile-id})
nil))]
(db/with-atomic [conn pool]
@@ -162,46 +179,52 @@
;; ---- COMMAND: Prepare Register
(defn validate-register-attempt!
[{:keys [::db/pool] :as cfg} params]
(defn- validate-register-attempt!
[cfg params]
(when-not (contains? cf/flags :registration)
(when-not (contains? params :invitation-token)
(ex/raise :type :restriction
:code :registration-disabled)))
(when (or
(not (contains? cf/flags :registration))
(not (contains? cf/flags :login-with-password)))
(ex/raise :type :restriction
:code :registration-disabled))
(when (contains? params :invitation-token)
(let [invitation (tokens/verify (::setup/props cfg) {:token (:invitation-token params) :iss :team-invitation})]
(let [invitation (tokens/verify (::setup/props cfg)
{:token (:invitation-token params)
:iss :team-invitation})]
(when-not (= (:email params) (:member-email invitation))
(ex/raise :type :restriction
:code :email-does-not-match-invitation
:hint "email should match the invitation"))))
(when-not (auth/email-domain-in-whitelist? (:email params))
(ex/raise :type :validation
(when (and (email.blacklist/enabled? cfg)
(email.blacklist/contains? cfg (:email params)))
(ex/raise :type :restriction
:code :email-domain-is-not-allowed))
;; Don't allow proceed in preparing registration if the profile is
;; already reported as spammer.
(when (eml/has-bounce-reports? pool (:email params))
(ex/raise :type :validation
:code :email-has-permanent-bounces
:hint "looks like the email has one or many bounces reported"))
(when (and (email.whitelist/enabled? cfg)
(not (email.whitelist/contains? cfg (:email params))))
(ex/raise :type :restriction
:code :email-domain-is-not-allowed))
;; Perform a basic validation of email & password
(when (= (str/lower (:email params))
(str/lower (:password params)))
(ex/raise :type :validation
:code :email-as-password
:hint "you can't use your email as password")))
:hint "you can't use your email as password"))
(def register-retry-threshold
(dt/duration "15m"))
(when (eml/has-bounce-reports? cfg (:email params))
(ex/raise :type :restriction
:code :email-has-permanent-bounces
:email (:email params)
:hint "looks like the email has bounce reports"))
(defn- elapsed-register-retry-threshold?
[profile]
(let [elapsed (dt/diff (:modified-at profile) (dt/now))]
(pos? (compare elapsed register-retry-threshold))))
(when (eml/has-complaint-reports? cfg (:email params))
(ex/raise :type :restriction
:code :email-has-complaints
:email (:email params)
:hint "looks like the email has complaint reports")))
(defn prepare-register
[{:keys [::db/pool] :as cfg} {:keys [email] :as params}]
@@ -209,21 +232,7 @@
(validate-register-attempt! cfg params)
(let [email (profile/clean-email email)
profile (when-let [profile (profile/get-profile-by-email pool email)]
(cond
(:is-blocked profile)
(ex/raise :type :restriction
:code :profile-blocked)
(and (not (:is-active profile))
(elapsed-register-retry-threshold? profile))
profile
:else
(ex/raise :type :validation
:code :email-already-exists
:hint "profile already exists")))
profile (profile/get-profile-by-email pool email)
params {:email email
:password (:password params)
:invitation-token (:invitation-token params)
@@ -233,8 +242,8 @@
:exp (dt/in-future {:days 7})}
params (d/without-nils params)
token (tokens/generate (::setup/props cfg) params)]
(with-meta {:token token}
{::audit/profile-id uuid/zero})))
@@ -277,6 +286,7 @@
is-demo (:is-demo params false)
is-muted (:is-muted params false)
is-active (:is-active params false)
theme (:theme params nil)
email (str/lower email)
params {:id id
@@ -287,20 +297,24 @@
:password password
:deleted-at (:deleted-at params)
:props props
:theme theme
:is-active is-active
:is-muted is-muted
:is-demo is-demo}]
(try
(-> (db/insert! conn :profile params)
(profile/decode-row))
(catch org.postgresql.util.PSQLException e
(let [state (.getSQLState e)]
(catch org.postgresql.util.PSQLException cause
(let [state (.getSQLState cause)]
(if (not= state "23505")
(throw e)
(ex/raise :type :validation
:code :email-already-exists
:hint "email already exists"
:cause e)))))))
(throw cause)
(do
(l/error :hint "not an error" :cause cause)
(ex/raise :type :validation
:code :email-already-exists
:hint "email already exists"
:cause cause))))))))
(defn create-profile-rels!
[conn {:keys [id] :as profile}]
@@ -317,17 +331,16 @@
{::db/return-keys true})
(profile/decode-row))))
(defn send-email-verification!
[conn props profile]
(let [vtoken (tokens/generate props
[{:keys [::db/conn] :as cfg} profile]
(let [vtoken (tokens/generate (::setup/props cfg)
{:iss :verify-email
:exp (dt/in-future "72h")
:profile-id (:id profile)
:email (:email profile)})
;; NOTE: this token is mainly used for possible complains
;; identification on the sns webhook
ptoken (tokens/generate props
ptoken (tokens/generate (::setup/props cfg)
{:iss :profile-identity
:profile-id (:id profile)
:exp (dt/in-future {:days 30})})]
@@ -340,95 +353,141 @@
:extra-data ptoken})))
(defn register-profile
[{:keys [::db/conn] :as cfg} {:keys [token fullname] :as params}]
(let [claims (tokens/verify (::setup/props cfg) {:token token :iss :prepared-register})
[{:keys [::db/conn ::wrk/executor] :as cfg} {:keys [token fullname theme] :as params}]
(let [theme (when (= theme "light") theme)
claims (tokens/verify (::setup/props cfg) {:token token :iss :prepared-register})
params (-> claims
(into params)
(assoc :fullname fullname))
is-active (or (:is-active params)
(not (contains? cf/flags :email-verification)))
(assoc :fullname fullname)
(assoc :theme theme))
profile (if-let [profile-id (:profile-id claims)]
(profile/get-profile conn profile-id)
(let [params (-> params
(assoc :is-active is-active)
(update :password #(profile/derive-password cfg %)))]
(->> (create-profile! conn params)
(create-profile-rels! conn))))
;; NOTE: we first try to match existing profile
;; by email, that in normal circumstances will
;; not return anything, but when a user tries to
;; reuse the same token multiple times, we need
;; to detect if the profile is already registered
(or (profile/get-profile-by-email conn (:email claims))
(let [is-active (or (boolean (:is-active claims))
(not (contains? cf/flags :email-verification)))
params (-> params
(assoc :is-active is-active)
(update :password #(profile/derive-password cfg %)))
profile (->> (create-profile! conn params)
(create-profile-rels! conn))]
(vary-meta profile assoc :created true))))
created? (-> profile meta :created true?)
invitation (when-let [token (:invitation-token params)]
(tokens/verify (::setup/props cfg) {:token token :iss :team-invitation}))]
(tokens/verify (::setup/props cfg) {:token token :iss :team-invitation}))
;; If profile is filled in claims, means it tries to register
;; again, so we proceed to update the modified-at attr
;; accordingly.
(when-let [id (:profile-id claims)]
(db/update! conn :profile {:modified-at (dt/now)} {:id id})
(audit/submit! cfg
{::audit/type "fact"
::audit/name "register-profile-retry"
::audit/profile-id id}))
props (audit/profile->props profile)
create-welcome-file-when-needed
(fn []
(when (:create-welcome-file params)
(let [cfg (dissoc cfg ::db/conn)]
(wrk/submit! executor (create-welcome-file cfg profile)))))]
(cond
;; If invitation token comes in params, this is because the
;; user comes from team-invitation process; in this case,
;; regenerate token and send back to the user a new invitation
;; token (and mark current session as logged). This happens
;; only if the invitation email matches with the register
;; email.
(and (some? invitation) (= (:email profile) (:member-email invitation)))
;; When profile is blocked, we just ignore it and return plain data
(:is-blocked profile)
(do
(l/wrn :hint "register attempt for already blocked profile"
:profile-id (str (:id profile))
:profile-email (:email profile))
(rph/with-meta {:email (:email profile)}
{::audit/replace-props props
::audit/context {:action "ignore-because-blocked"}
::audit/profile-id (:id profile)
::audit/name "register-profile-retry"}))
;; If invitation token comes in params, this is because the user
;; comes from team-invitation process; in this case, regenerate
;; token and send back to the user a new invitation token (and
;; mark current session as logged). This happens only if the
;; invitation email matches with the register email.
(and (some? invitation)
(= (:email profile)
(:member-email invitation)))
(let [claims (assoc invitation :member-id (:id profile))
token (tokens/generate (::setup/props cfg) claims)
resp {:invitation-token token}]
(-> resp
token (tokens/generate (::setup/props cfg) claims)]
(-> {:invitation-token token}
(rph/with-transform (session/create-fn cfg (:id profile)))
(rph/with-meta {::audit/replace-props (audit/profile->props profile)
(rph/with-meta {::audit/replace-props props
::audit/context {:action "accept-invitation"}
::audit/profile-id (:id profile)})))
;; If auth backend is different from "penpot" means user is
;; registering using third party auth mechanism; in this case
;; we need to mark this session as logged.
(not= "penpot" (:auth-backend profile))
(-> (profile/strip-private-attrs profile)
(rph/with-transform (session/create-fn cfg (:id profile)))
(rph/with-meta {::audit/replace-props (audit/profile->props profile)
::audit/profile-id (:id profile)}))
;; When a new user is created and it is already activated by
;; configuration or specified by OIDC, we just mark the profile
;; as logged-in
created?
(if (:is-active profile)
(-> (profile/strip-private-attrs profile)
(rph/with-transform (session/create-fn cfg (:id profile)))
(rph/with-defer create-welcome-file-when-needed)
(rph/with-meta
{::audit/replace-props props
::audit/context {:action "login"}
::audit/profile-id (:id profile)}))
;; If the `:enable-insecure-register` flag is set, we proceed
;; to sign in the user directly, without email verification.
(true? is-active)
(-> (profile/strip-private-attrs profile)
(rph/with-transform (session/create-fn cfg (:id profile)))
(rph/with-meta {::audit/replace-props (audit/profile->props profile)
::audit/profile-id (:id profile)}))
(do
(when-not (eml/has-reports? conn (:email profile))
(send-email-verification! cfg profile))
(-> {:email (:email profile)}
(rph/with-defer create-welcome-file-when-needed)
(rph/with-meta
{::audit/replace-props props
::audit/context {:action "email-verification"}
::audit/profile-id (:id profile)}))))
;; In all other cases, send a verification email.
:else
(do
(send-email-verification! conn (::setup/props cfg) profile)
(rph/with-meta profile
(let [elapsed? (elapsed-verify-threshold? profile)
reports? (eml/has-reports? conn (:email profile))
action (if reports?
"ignore-because-complaints"
(if elapsed?
"resend-email-verification"
"ignore"))]
(l/wrn :hint "repeated registry detected"
:profile-id (str (:id profile))
:profile-email (:email profile)
:context-action action)
(when (= action "resend-email-verification")
(db/update! conn :profile
{:modified-at (dt/now)}
{:id (:id profile)})
(send-email-verification! cfg profile))
(rph/with-meta {:email (:email profile)}
{::audit/replace-props (audit/profile->props profile)
::audit/profile-id (:id profile)})))))
::audit/context {:action action}
::audit/profile-id (:id profile)
::audit/name "register-profile-retry"})))))
(def schema:register-profile
[:map {:title "register-profile"}
[:token schema:token]
[:fullname [::sm/word-string {:max 100}]]])
[:fullname [::sm/word-string {:max 100}]]
[:theme {:optional true} [:string {:max 10}]]
[:create-welcome-file {:optional true} :boolean]])
(sv/defmethod ::register-profile
{::rpc/auth false
::doc/added "1.15"
::sm/params schema:register-profile
::climit/id :auth/global}
[{:keys [::db/pool] :as cfg} params]
(db/with-atomic [conn pool]
(-> (assoc cfg ::db/conn conn)
(register-profile params))))
[cfg params]
(db/tx-run! cfg register-profile params))
;; ---- COMMAND: Request Profile Recovery
(defn request-profile-recovery
[{:keys [::db/pool] :as cfg} {:keys [email] :as params}]
(defn- request-profile-recovery
[{:keys [::db/conn] :as cfg} {:keys [email] :as params}]
(letfn [(create-recovery-token [{:keys [id] :as profile}]
(let [token (tokens/generate (::setup/props cfg)
{:iss :password-recovery
@@ -450,28 +509,42 @@
:extra-data ptoken})
nil))]
(db/with-atomic [conn pool]
(when-let [profile (->> (profile/clean-email email)
(profile/get-profile-by-email conn))]
(when-not (eml/allow-send-emails? conn profile)
(ex/raise :type :validation
:code :profile-is-muted
:hint "looks like the profile has reported repeatedly as spam or has permanent bounces."))
(let [profile (->> (profile/clean-email email)
(profile/get-profile-by-email conn))]
(when-not (:is-active profile)
(ex/raise :type :validation
:code :profile-not-verified
:hint "the user need to validate profile before recover password"))
(cond
(not profile)
(l/wrn :hint "attempt of profile recovery: no profile found"
:profile-email email)
(when (eml/has-bounce-reports? conn (:email profile))
(ex/raise :type :validation
:code :email-has-permanent-bounces
:hint "looks like the email you invite has been repeatedly reported as spam or permanent bounce"))
(not (eml/allow-send-emails? conn profile))
(l/wrn :hint "attempt of profile recovery: profile is muted"
:profile-id (str (:id profile))
:profile-email (:email profile))
(->> profile
(create-recovery-token)
(send-email-notification conn))))))
(eml/has-bounce-reports? conn (:email profile))
(l/wrn :hint "attempt of profile recovery: email has bounces"
:profile-id (str (:id profile))
:profile-email (:email profile))
(eml/has-complaint-reports? conn (:email profile))
(l/wrn :hint "attempt of profile recovery: email has complaints"
:profile-id (str (:id profile))
:profile-email (:email profile))
(not (elapsed-verify-threshold? profile))
(l/wrn :hint "attempt of profile recovery: retry attempt threshold not elapsed"
:profile-id (str (:id profile))
:profile-email (:email profile))
:else
(do
(db/update! conn :profile
{:modified-at (dt/now)}
{:id (:id profile)})
(->> profile
(create-recovery-token)
(send-email-notification conn)))))))
(def schema:request-profile-recovery
[:map {:title "request-profile-recovery"}
@@ -482,6 +555,6 @@
::doc/added "1.15"
::sm/params schema:request-profile-recovery}
[cfg params]
(request-profile-recovery cfg params))
(db/tx-run! cfg request-profile-recovery params))

View File

@@ -32,12 +32,11 @@
(def ^:private
schema:export-binfile
(sm/define
[:map {:title "export-binfile"}
[:name :string]
[:file-id ::sm/uuid]
[:include-libraries :boolean]
[:embed-assets :boolean]]))
[:map {:title "export-binfile"}
[:name [:string {:max 250}]]
[:file-id ::sm/uuid]
[:include-libraries :boolean]
[:embed-assets :boolean]])
(sv/defmethod ::export-binfile
"Export a penpot file in a binary format."
@@ -78,11 +77,10 @@
(def ^:private
schema:import-binfile
(sm/define
[:map {:title "import-binfile"}
[:name :string]
[:project-id ::sm/uuid]
[:file ::media/upload]]))
[:map {:title "import-binfile"}
[:name [:string {:max 250}]]
[:project-id ::sm/uuid]
[:file ::media/upload]])
(sv/defmethod ::import-binfile
"Import a penpot file in a binary format."

View File

@@ -292,7 +292,7 @@
[:map {:title "create-comment-thread"}
[:file-id ::sm/uuid]
[:position ::gpt/point]
[:content :string]
[:content [:string {:max 750}]]
[:page-id ::sm/uuid]
[:frame-id ::sm/uuid]
[:share-id {:optional true} [:maybe ::sm/uuid]]])
@@ -418,7 +418,7 @@
schema:create-comment
[:map {:title "create-comment"}
[:thread-id ::sm/uuid]
[:content :string]
[:content [:string {:max 250}]]
[:share-id {:optional true} [:maybe ::sm/uuid]]])
(sv/defmethod ::create-comment
@@ -477,7 +477,7 @@
schema:update-comment
[:map {:title "update-comment"}
[:id ::sm/uuid]
[:content :string]
[:content [:string {:max 250}]]
[:share-id {:optional true} [:maybe ::sm/uuid]]])
(sv/defmethod ::update-comment

View File

@@ -18,10 +18,7 @@
[app.util.services :as sv]
[app.util.time :as dt]
[buddy.core.codecs :as bc]
[buddy.core.nonce :as bn]
[clojure.spec.alpha :as s]))
(s/def ::create-demo-profile any?)
[buddy.core.nonce :as bn]))
(sv/defmethod ::create-demo-profile
"A command that is responsible of creating a demo purpose
@@ -48,7 +45,7 @@
params {:email email
:fullname fullname
:is-active true
:deleted-at (dt/in-future cf/deletion-delay)
:deleted-at (dt/in-future (cf/get-deletion-delay))
:password (profile/derive-password cfg password)
:props {}}]

View File

@@ -8,29 +8,25 @@
"A general purpose feedback module."
(:require
[app.common.exceptions :as ex]
[app.common.spec :as us]
[app.common.schema :as sm]
[app.config :as cf]
[app.db :as db]
[app.email :as eml]
[app.rpc :as-alias rpc]
[app.rpc.commands.profile :as profile]
[app.rpc.doc :as-alias doc]
[app.util.services :as sv]
[clojure.spec.alpha :as s]))
[app.util.services :as sv]))
(declare ^:private send-feedback!)
(s/def ::content ::us/string)
(s/def ::from ::us/email)
(s/def ::subject ::us/string)
(s/def ::send-user-feedback
(s/keys :req [::rpc/profile-id]
:req-un [::subject
::content]))
(def ^:private schema:send-user-feedback
[:map {:title "send-user-feedback"}
[:subject [:string {:max 250}]]
[:content [:string {:max 250}]]])
(sv/defmethod ::send-user-feedback
{::doc/added "1.18"}
{::doc/added "1.18"
::sm/params schema:send-user-feedback}
[{:keys [::db/pool]} {:keys [::rpc/profile-id] :as params}]
(when-not (contains? cf/flags :user-feedback)
(ex/raise :type :restriction

View File

@@ -15,7 +15,6 @@
[app.common.logging :as l]
[app.common.schema :as sm]
[app.common.schema.desc-js-like :as-alias smdj]
[app.common.spec :as us]
[app.common.types.components-list :as ctkl]
[app.common.types.file :as ctf]
[app.config :as cf]
@@ -35,7 +34,7 @@
[app.util.pointer-map :as pmap]
[app.util.services :as sv]
[app.util.time :as dt]
[clojure.spec.alpha :as s]
[app.worker :as wrk]
[cuerdas.core :as str]))
;; --- FEATURES
@@ -45,18 +44,6 @@
(when media-id
(str (cf/get :public-uri) "/assets/by-id/" media-id)))
;; --- SPECS
(s/def ::features ::us/set-of-strings)
(s/def ::file-id ::us/uuid)
(s/def ::frame-id ::us/uuid)
(s/def ::id ::us/uuid)
(s/def ::is-shared ::us/boolean)
(s/def ::name ::us/string)
(s/def ::project-id ::us/uuid)
(s/def ::search-term ::us/string)
(s/def ::team-id ::us/uuid)
;; --- HELPERS
(def long-cache-duration
@@ -81,6 +68,9 @@
:max-version fmg/version))
file))
;; --- FILE DATA
;; --- FILE PERMISSIONS
(def ^:private sql:file-permissions
@@ -188,12 +178,12 @@
[:map {:title "File"}
[:id ::sm/uuid]
[:features ::cfeat/features]
[:has-media-trimmed :boolean]
[:comment-thread-seqn {:min 0} :int]
[:name :string]
[:revn {:min 0} :int]
[:has-media-trimmed ::sm/boolean]
[:comment-thread-seqn [::sm/int {:min 0}]]
[:name [:string {:max 250}]]
[:revn [::sm/int {:min 0}]]
[:modified-at ::dt/instant]
[:is-shared :boolean]
[:is-shared ::sm/boolean]
[:project-id ::sm/uuid]
[:created-at ::dt/instant]
[:data {:optional true} :any]]))
@@ -271,18 +261,19 @@
(let [params (merge {:id id}
(when (some? project-id)
{:project-id project-id}))
file (-> (db/get conn :file params
{::db/check-deleted (not include-deleted?)
::db/remove-deleted (not include-deleted?)
::sql/for-update lock-for-update?})
(decode-row))]
file (->> (db/get conn :file params
{::db/check-deleted (not include-deleted?)
::db/remove-deleted (not include-deleted?)
::sql/for-update lock-for-update?})
(feat.fdata/resolve-file-data cfg)
(decode-row))]
(if (and migrate? (fmg/need-migration? file))
(migrate-file cfg file)
file)))
(defn get-minimal-file
[cfg id & {:as opts}]
(let [opts (assoc opts ::sql/columns [:id :modified-at :revn])]
(let [opts (assoc opts ::sql/columns [:id :modified-at :deleted-at :revn :data-ref-id :data-backend])]
(db/get cfg :file {:id id} opts)))
(defn get-file-etag
@@ -340,9 +331,11 @@
[:share-id {:optional true} ::sm/uuid]])
(defn- get-file-fragment
[conn file-id fragment-id]
(some-> (db/get conn :file-data-fragment {:file-id file-id :id fragment-id})
(update :content blob/decode)))
[cfg file-id fragment-id]
(let [resolve-file-data (partial feat.fdata/resolve-file-data cfg)]
(some-> (db/get cfg :file-data-fragment {:file-id file-id :id fragment-id})
(resolve-file-data)
(update :data blob/decode))))
(sv/defmethod ::get-file-fragment
"Retrieve a file fragment by its ID. Only authenticated users."
@@ -350,12 +343,12 @@
::rpc/auth false
::sm/params schema:get-file-fragment
::sm/result schema:file-fragment}
[{:keys [::db/pool] :as cfg} {:keys [::rpc/profile-id file-id fragment-id share-id]}]
(dm/with-open [conn (db/open pool)]
(let [perms (get-permissions conn profile-id file-id share-id)]
(check-read-permissions! perms)
(-> (get-file-fragment conn file-id fragment-id)
(rph/with-http-cache long-cache-duration)))))
[cfg {:keys [::rpc/profile-id file-id fragment-id share-id]}]
(db/run! cfg (fn [cfg]
(let [perms (get-permissions cfg profile-id file-id share-id)]
(check-read-permissions! perms)
(-> (get-file-fragment cfg file-id fragment-id)
(rph/with-http-cache long-cache-duration))))))
;; --- COMMAND QUERY: get-project-files
@@ -415,7 +408,7 @@
"Checks if the file has libraries. Returns a boolean"
{::doc/added "1.15.1"
::sm/params schema:has-file-libraries
::sm/result :boolean}
::sm/result ::sm/boolean}
[{:keys [::db/pool] :as cfg} {:keys [::rpc/profile-id file-id]}]
(dm/with-open [conn (db/open pool)]
(check-read-permissions! pool profile-id file-id)
@@ -494,7 +487,7 @@
[:file-id ::sm/uuid]
[:page-id {:optional true} ::sm/uuid]
[:share-id {:optional true} ::sm/uuid]
[:object-id {:optional true} [:or ::sm/uuid ::sm/coll-of-uuid]]
[:object-id {:optional true} [:or ::sm/uuid [::sm/set ::sm/uuid]]]
[:features {:optional true} ::cfeat/features]])
(sv/defmethod ::get-page
@@ -670,7 +663,7 @@
f.modified_at,
f.name,
f.is_shared,
ft.media_id,
ft.media_id AS thumbnail_id,
row_number() over w as row_num
from file as f
inner join project as p on (p.id = f.project_id)
@@ -689,10 +682,8 @@
[conn team-id]
(->> (db/exec! conn [sql:team-recent-files team-id])
(mapv (fn [row]
(if-let [media-id (:media-id row)]
(-> row
(dissoc :media-id)
(assoc :thumbnail-uri (resolve-public-uri media-id)))
(if-let [media-id (:thumbnail-id row)]
(assoc row :thumbnail-uri (resolve-public-uri media-id))
(dissoc row :media-id))))))
(def ^:private schema:get-team-recent-files
@@ -738,6 +729,23 @@
[cfg {:keys [::rpc/profile-id] :as params}]
(db/tx-run! cfg get-file-summary (assoc params :profile-id profile-id)))
;; --- COMMAND QUERY: get-file-info
(defn- get-file-info
[{:keys [::db/conn] :as cfg} {:keys [id] :as params}]
(db/get* conn :file
{:id id}
{::sql/columns [:id]}))
(sv/defmethod ::get-file-info
"Retrieve minimal file info by its ID."
{::rpc/auth false
::doc/added "2.2.0"
::sm/params schema:get-file}
[cfg params]
(db/tx-run! cfg get-file-info params))
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;; MUTATION COMMANDS
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
@@ -760,19 +768,19 @@
[:map {:title "RenameFileEvent"}
[:id ::sm/uuid]
[:project-id ::sm/uuid]
[:name :string]
[:name [:string {:max 250}]]
[:created-at ::dt/instant]
[:modified-at ::dt/instant]]
::sm/params
[:map {:title "RenameFileParams"}
[:name {:min 1} :string]
[:name [:string {:min 1 :max 250}]]
[:id ::sm/uuid]]
::sm/result
[:map {:title "SimplifiedFile"}
[:id ::sm/uuid]
[:name :string]
[:name [:string {:max 250}]]
[:created-at ::dt/instant]
[:modified-at ::dt/instant]]}
@@ -817,12 +825,13 @@
(db/update! cfg :file
{:revn (inc (:revn file))
:data (blob/encode (:data file))
:modified-at (dt/now)}
:modified-at (dt/now)
:has-media-trimmed false}
{:id file-id})
(feat.fdata/persist-pointers! cfg file-id))))
(defn- absorb-library!
(defn- absorb-library
"Find all files using a shared library, and absorb all library assets
into the file local libraries"
[cfg {:keys [id] :as library}]
@@ -840,7 +849,26 @@
:library-id (str id)
:files (str/join "," (map str ids)))
(run! (partial absorb-library-by-file! cfg ldata) ids)))
(run! (partial absorb-library-by-file! cfg ldata) ids)
library))
(defn absorb-library!
[{:keys [::db/conn] :as cfg} id]
(let [file (-> (get-file cfg id
:lock-for-update? true
:include-deleted? true)
(check-version!))
proj (db/get* conn :project {:id (:project-id file)}
{::db/remove-deleted false})
team (-> (db/get* conn :team {:id (:team-id proj)}
{::db/remove-deleted false})
(teams/decode-row))]
(-> (cfeat/get-team-enabled-features cf/flags team)
(cfeat/check-file-features! (:features file)))
(absorb-library cfg file)))
(defn- set-file-shared
[{:keys [::db/conn] :as cfg} {:keys [profile-id id] :as params}]
@@ -853,25 +881,14 @@
;; file, we need to perform more complex operation,
;; so in this case we retrieve the complete file and
;; perform all required validations.
(let [file (-> (get-file cfg id :lock-for-update? true)
(check-version!)
(assoc :is-shared false))
team (teams/get-team conn
:profile-id profile-id
:project-id (:project-id file))]
(-> (cfeat/get-team-enabled-features cf/flags team)
(cfeat/check-client-features! (:features params))
(cfeat/check-file-features! (:features file)))
(absorb-library! cfg file)
(let [file (-> (absorb-library! cfg id)
(assoc :is-shared false))]
(db/delete! conn :file-library-rel {:library-file-id id})
(db/update! conn :file
{:is-shared false
:modified-at (dt/now)}
{:id id})
file)
(select-keys file [:id :name :is-shared]))
(and (false? (:is-shared file))
(true? (:is-shared params)))
@@ -900,7 +917,7 @@
(sm/define
[:map {:title "set-file-shared"}
[:id ::sm/uuid]
[:is-shared :boolean]]))
[:is-shared ::sm/boolean]]))
(sv/defmethod ::set-file-shared
{::doc/added "1.17"
@@ -911,12 +928,19 @@
;; --- MUTATION COMMAND: delete-file
(defn- mark-file-deleted!
(defn- mark-file-deleted
[conn file-id]
(db/update! conn :file
{:deleted-at (dt/now)}
{:id file-id}
{::db/return-keys [:id :name :is-shared :project-id :created-at :modified-at]}))
(let [file (db/update! conn :file
{:deleted-at (dt/now)}
{:id file-id}
{::db/return-keys [:id :name :is-shared :deleted-at
:project-id :created-at :modified-at]})]
(wrk/submit! {::db/conn conn
::wrk/task :delete-object
::wrk/params {:object :file
:deleted-at (:deleted-at file)
:id file-id}})
file))
(def ^:private
schema:delete-file
@@ -927,29 +951,7 @@
(defn- delete-file
[{:keys [::db/conn] :as cfg} {:keys [profile-id id] :as params}]
(check-edition-permissions! conn profile-id id)
(let [file (mark-file-deleted! conn id)]
;; NOTE: when a file is a shared library, then we proceed to load
;; the whole file, proceed with feature checking and properly execute
;; the absorb-library procedure
(when (:is-shared file)
(let [file (-> (get-file cfg id
:lock-for-update? true
:include-deleted? true)
(check-version!))
team (teams/get-team conn
:profile-id profile-id
:project-id (:project-id file))]
(-> (cfeat/get-team-enabled-features cf/flags team)
(cfeat/check-client-features! (:features params))
(cfeat/check-file-features! (:features file)))
(absorb-library! cfg file)))
(let [file (mark-file-deleted conn id)]
(rph/with-meta (rph/wrap)
{::audit/props {:project-id (:project-id file)
:name (:name file)
@@ -1053,14 +1055,16 @@
{:id file-id}
{::db/return-keys true}))
(s/def ::ignore-file-library-sync-status
(s/keys :req [::rpc/profile-id]
:req-un [::file-id ::date]))
(def ^:private schema:ignore-file-library-sync-status
[:map {:title "ignore-file-library-sync-status"}
[:file-id ::sm/uuid]
[:date ::dt/instant]])
;; TODO: improve naming
(sv/defmethod ::ignore-file-library-sync-status
"Ignore updates in linked files"
{::doc/added "1.17"}
{::doc/added "1.17"
::sm/params schema:ignore-file-library-sync-status}
[{:keys [::db/pool] :as cfg} {:keys [::rpc/profile-id file-id] :as params}]
(db/with-atomic [conn pool]
(check-edition-permissions! conn profile-id file-id)

View File

@@ -6,13 +6,10 @@
(ns app.rpc.commands.files-create
(:require
[app.common.data :as d]
[app.common.data.macros :as dm]
[app.common.features :as cfeat]
[app.common.files.defaults :refer [version]]
[app.common.schema :as sm]
[app.common.types.file :as ctf]
[app.common.uuid :as uuid]
[app.config :as cf]
[app.db :as db]
[app.features.fdata :as feat.fdata]
@@ -40,7 +37,7 @@
(defn create-file
[{:keys [::db/conn] :as cfg}
{:keys [id name project-id is-shared revn
modified-at deleted-at create-page
modified-at deleted-at create-page page-id
ignore-sync-until features]
:or {is-shared false revn 0 create-page true}
:as params}]
@@ -51,23 +48,17 @@
(binding [pmap/*tracked* (pmap/create-tracked)
cfeat/*current* features]
(let [id (or id (uuid/next))
data (if create-page
(ctf/make-file-data id)
(ctf/make-file-data id nil))
file {:id id
:project-id project-id
:name name
:revn revn
:is-shared is-shared
:version version
:data data
:features features
:ignore-sync-until ignore-sync-until
:modified-at modified-at
:deleted-at deleted-at}
(let [file (ctf/make-file {:id id
:project-id project-id
:name name
:revn revn
:is-shared is-shared
:features features
:ignore-sync-until ignore-sync-until
:modified-at modified-at
:deleted-at deleted-at
:create-page create-page
:page-id page-id})
file (if (contains? features "fdata/objects-map")
(feat.fdata/enable-objects-map file)
@@ -75,9 +66,7 @@
file (if (contains? features "fdata/pointer-map")
(feat.fdata/enable-pointer-map file)
file)
file (d/without-nils file)]
file)]
(db/insert! conn :file
(-> file
@@ -86,9 +75,9 @@
{::db/return-keys false})
(when (contains? features "fdata/pointer-map")
(feat.fdata/persist-pointers! cfg id))
(feat.fdata/persist-pointers! cfg (:id file)))
(->> (assoc params :file-id id :role :owner)
(->> (assoc params :file-id (:id file) :role :owner)
(create-file-role! conn))
(db/update! conn :project
@@ -99,10 +88,10 @@
(def ^:private schema:create-file
[:map {:title "create-file"}
[:name :string]
[:name [:string {:max 250}]]
[:project-id ::sm/uuid]
[:id {:optional true} ::sm/uuid]
[:is-shared {:optional true} :boolean]
[:is-shared {:optional true} ::sm/boolean]
[:features {:optional true} ::cfeat/features]])
(sv/defmethod ::create-file

View File

@@ -7,29 +7,24 @@
(ns app.rpc.commands.files-share
"Share link related rpc mutation methods."
(:require
[app.common.spec :as us]
[app.common.schema :as sm]
[app.common.uuid :as uuid]
[app.db :as db]
[app.rpc :as-alias rpc]
[app.rpc.commands.files :as files]
[app.rpc.doc :as-alias doc]
[app.util.services :as sv]
[clojure.spec.alpha :as s]))
;; --- Helpers & Specs
(s/def ::file-id ::us/uuid)
(s/def ::who-comment ::us/string)
(s/def ::who-inspect ::us/string)
(s/def ::pages (s/every ::us/uuid :kind set?))
[app.util.services :as sv]))
;; --- MUTATION: Create Share Link
(declare create-share-link)
(s/def ::create-share-link
(s/keys :req [::rpc/profile-id]
:req-un [::file-id ::who-comment ::who-inspect ::pages]))
(def ^:private schema:create-share-link
[:map {:title "create-share-link"}
[:file-id ::sm/uuid]
[:who-comment [:string {:max 250}]]
[:who-inspect [:string {:max 250}]]
[:pages [:set ::sm/uuid]]])
(sv/defmethod ::create-share-link
"Creates a share-link object.
@@ -37,7 +32,8 @@
Share links are resources that allows external users access to specific
pages of a file with specific permissions (who-comment and who-inspect)."
{::doc/added "1.18"
::doc/module :files}
::doc/module :files
::sm/params schema:create-share-link}
[{:keys [::db/pool] :as cfg} {:keys [::rpc/profile-id file-id] :as params}]
(db/with-atomic [conn pool]
(files/check-edition-permissions! conn profile-id file-id)
@@ -58,13 +54,14 @@
;; --- MUTATION: Delete Share Link
(s/def ::delete-share-link
(s/keys :req [::rpc/profile-id]
:req-un [::us/id]))
(def ^:private schema:delete-share-link
[:map {:title "delete-share-link"}
[:id ::sm/uuid]])
(sv/defmethod ::delete-share-link
{::doc/added "1.18"
::doc/module ::files}
::doc/module ::files
::sm/params schema:delete-share-link}
[{:keys [::db/pool] :as cfg} {:keys [::rpc/profile-id id] :as params}]
(db/with-atomic [conn pool]
(let [slink (db/get-by-id conn :share-link id)]

View File

@@ -13,13 +13,15 @@
[app.config :as cf]
[app.db :as db]
[app.db.sql :as-alias sql]
[app.features.fdata :as feat.fdata]
[app.main :as-alias main]
[app.media :as media]
[app.rpc :as-alias rpc]
[app.rpc.commands.files :as files]
[app.rpc.commands.profile :as profile]
[app.rpc.doc :as-alias doc]
[app.storage :as sto]
[app.util.blob :as blob]
[app.util.pointer-map :as pmap]
[app.util.services :as sv]
[app.util.time :as dt]
[cuerdas.core :as str]))
@@ -34,20 +36,21 @@
:code :authentication-required
:hint "only admins allowed")))
(def sql:get-file-snapshots
"SELECT id, label, revn, created_at
FROM file_change
WHERE file_id = ?
AND created_at < ?
AND label IS NOT NULL
ORDER BY created_at DESC
LIMIT ?")
(defn get-file-snapshots
[{:keys [::db/conn]} {:keys [file-id limit start-at]
:or {limit Long/MAX_VALUE}}]
(let [query (str "select id, label, revn, created_at "
" from file_change "
" where file_id = ? "
" and created_at < ? "
" and data is not null "
" order by created_at desc "
" limit ?")
start-at (or start-at (dt/now))
(let [start-at (or start-at (dt/now))
limit (min limit 20)]
(->> (db/exec! conn [query file-id start-at limit])
(->> (db/exec! conn [sql:get-file-snapshots file-id start-at limit])
(mapv (fn [row]
(update row :created-at dt/format-instant :rfc1123))))))
@@ -63,8 +66,8 @@
(db/run! cfg get-file-snapshots params))
(defn restore-file-snapshot!
[{:keys [::db/conn ::sto/storage] :as cfg} {:keys [file-id id]}]
(let [storage (media/configure-assets-storage storage conn)
[{:keys [::db/conn] :as cfg} {:keys [file-id id]}]
(let [storage (sto/resolve cfg {::db/reuse-conn true})
file (files/get-minimal-file conn file-id {::db/for-update true})
snapshot (db/get* conn :file-change
{:file-id file-id
@@ -78,43 +81,53 @@
:id id
:file-id file-id))
(when-not (:data snapshot)
(ex/raise :type :precondition
:code :snapshot-without-data
:hint "snapshot has no data"
:label (:label snapshot)
:file-id file-id))
(let [snapshot (feat.fdata/resolve-file-data cfg snapshot)]
(when-not (:data snapshot)
(ex/raise :type :precondition
:code :snapshot-without-data
:hint "snapshot has no data"
:label (:label snapshot)
:file-id file-id))
(l/dbg :hint "restoring snapshot"
:file-id (str file-id)
:label (:label snapshot)
:snapshot-id (str (:id snapshot)))
(l/dbg :hint "restoring snapshot"
:file-id (str file-id)
:label (:label snapshot)
:snapshot-id (str (:id snapshot)))
(db/update! conn :file
{:data (:data snapshot)
:revn (inc (:revn file))
:features (:features snapshot)}
{:id file-id})
;; If the file was already offloaded, on restring the snapshot
;; we are going to replace the file data, so we need to touch
;; the old referenced storage object and avoid possible leaks
(when (feat.fdata/offloaded? file)
(sto/touch-object! storage (:data-ref-id file)))
;; clean object thumbnails
(let [sql (str "update file_tagged_object_thumbnail "
" set deleted_at = now() "
" where file_id=? returning media_id")
res (db/exec! conn [sql file-id])]
(db/update! conn :file
{:data (:data snapshot)
:revn (inc (:revn file))
:version (:version snapshot)
:data-backend nil
:data-ref-id nil
:has-media-trimmed false
:features (:features snapshot)}
{:id file-id})
(doseq [media-id (into #{} (keep :media-id) res)]
(sto/touch-object! storage media-id)))
;; clean object thumbnails
(let [sql (str "update file_tagged_object_thumbnail "
" set deleted_at = now() "
" where file_id=? returning media_id")
res (db/exec! conn [sql file-id])]
(doseq [media-id (into #{} (keep :media-id) res)]
(sto/touch-object! storage media-id)))
;; clean object thumbnails
(let [sql (str "update file_thumbnail "
" set deleted_at = now() "
" where file_id=? returning media_id")
res (db/exec! conn [sql file-id])]
(doseq [media-id (into #{} (keep :media-id) res)]
(sto/touch-object! storage media-id)))
;; clean file thumbnails
(let [sql (str "update file_thumbnail "
" set deleted_at = now() "
" where file_id=? returning media_id")
res (db/exec! conn [sql file-id])]
(doseq [media-id (into #{} (keep :media-id) res)]
(sto/touch-object! storage media-id)))
{:id (:id snapshot)
:label (:label snapshot)}))
{:id (:id snapshot)
:label (:label snapshot)})))
(defn- resolve-snapshot-by-label
[conn file-id label]
@@ -146,21 +159,33 @@
(merge (resolve-snapshot-by-label conn file-id label)))]
(restore-file-snapshot! cfg params)))))
(defn- get-file
[cfg file-id]
(let [file (->> (db/get cfg :file {:id file-id})
(feat.fdata/resolve-file-data cfg))]
(binding [pmap/*load-fn* (partial feat.fdata/load-pointer cfg file-id)]
(-> file
(update :data blob/decode)
(update :data feat.fdata/process-pointers deref)
(update :data feat.fdata/process-objects (partial into {}))
(update :data blob/encode)))))
(defn take-file-snapshot!
[cfg {:keys [file-id label]}]
(let [conn (db/get-connection cfg)
file (db/get conn :file {:id file-id})
[cfg {:keys [file-id label ::rpc/profile-id]}]
(let [file (get-file cfg file-id)
id (uuid/next)]
(l/debug :hint "creating file snapshot"
:file-id (str file-id)
:label label)
(db/insert! conn :file-change
(db/insert! cfg :file-change
{:id id
:revn (:revn file)
:data (:data file)
:version (:version file)
:features (:features file)
:profile-id profile-id
:file-id (:id file)
:label label}
{::db/return-keys false})

View File

@@ -16,6 +16,7 @@
[app.db.sql :as sql]
[app.features.components-v2 :as feat.compv2]
[app.features.fdata :as fdata]
[app.loggers.audit :as audit]
[app.rpc :as-alias rpc]
[app.rpc.commands.files :as files]
[app.rpc.commands.files-create :as files.create]
@@ -23,6 +24,7 @@
[app.rpc.commands.projects :as projects]
[app.rpc.commands.teams :as teams]
[app.rpc.doc :as-alias doc]
[app.rpc.helpers :as rph]
[app.util.blob :as blob]
[app.util.pointer-map :as pmap]
[app.util.services :as sv]
@@ -33,12 +35,12 @@
(def ^:private schema:create-temp-file
[:map {:title "create-temp-file"}
[:name :string]
[:name [:string {:max 250}]]
[:project-id ::sm/uuid]
[:id {:optional true} ::sm/uuid]
[:is-shared :boolean]
[:is-shared ::sm/boolean]
[:features ::cfeat/features]
[:create-page :boolean]])
[:create-page ::sm/boolean]])
(sv/defmethod ::create-temp-file
{::doc/added "1.17"
@@ -81,7 +83,7 @@
(def ^:private schema:update-temp-file
[:map {:title "update-temp-file"}
[:changes [:vector ::cpc/change]]
[:revn {:min 0} :int]
[:revn [::sm/int {:min 0}]]
[:session-id ::sm/uuid]
[:id ::sm/uuid]])
@@ -100,7 +102,9 @@
:revn revn
:data nil
:changes (blob/encode changes)})
nil)))
(rph/with-meta (rph/wrap nil)
{::audit/replace-props {:file-id id
:revn revn}}))))
;; --- MUTATION COMMAND: persist-temp-file

View File

@@ -33,7 +33,6 @@
[app.util.pointer-map :as pmap]
[app.util.services :as sv]
[app.util.time :as dt]
[clojure.spec.alpha :as s]
[cuerdas.core :as str]))
;; --- FEATURES
@@ -86,11 +85,8 @@
::doc/module :files
::sm/params [:map {:title "get-file-object-thumbnails"}
[:file-id ::sm/uuid]
[:tag {:optional true} :string]]
::sm/result [:map-of :string :string]
::cond/get-object #(files/get-minimal-file %1 (:file-id %2))
::cond/reuse-key? true
::cond/key-fn files/get-file-etag}
[:tag {:optional true} [:string {:max 50}]]]
::sm/result [:map-of [:string {:max 250}] [:string {:max 250}]]}
[{:keys [::db/pool] :as cfg} {:keys [::rpc/profile-id file-id tag] :as params}]
(dm/with-open [conn (db/open pool)]
(files/check-read-permissions! conn profile-id file-id)
@@ -193,7 +189,7 @@
(sm/define
[:map {:title "PartialFile"}
[:id ::sm/uuid]
[:revn {:min 0} :int]
[:revn {:min 0} ::sm/int]
[:page :any]]))
(sv/defmethod ::get-file-data-for-thumbnail
@@ -237,7 +233,7 @@
"INSERT INTO file_tagged_object_thumbnail (file_id, object_id, tag, media_id)
VALUES (?, ?, ?, ?)
ON CONFLICT (file_id, object_id, tag)
DO UPDATE SET updated_at=?, media_id=?, deleted_at=null
DO UPDATE SET updated_at=?, media_id=?, deleted_at=?
RETURNING *")
(defn- persist-thumbnail!
@@ -255,17 +251,19 @@
:content-type mtype
:bucket "file-object-thumbnail"})))
(defn- create-file-object-thumbnail!
[{:keys [::sto/storage] :as cfg} file-id object-id media tag]
(let [tsnow (dt/now)
media (persist-thumbnail! storage media tsnow)
[{:keys [::sto/storage] :as cfg} file object-id media tag]
(let [file-id (:id file)
timestamp (dt/now)
media (persist-thumbnail! storage media timestamp)
[th1 th2] (db/tx-run! cfg (fn [{:keys [::db/conn]}]
(let [th1 (db/exec-one! conn [sql:get-file-object-thumbnail file-id object-id tag])
th2 (db/exec-one! conn [sql:create-file-object-thumbnail
file-id object-id tag (:id media)
tsnow (:id media)])]
file-id object-id tag
(:id media)
timestamp
(:id media)
(:deleted-at file)])]
[th1 th2])))]
(when (and (some? th1)
@@ -279,9 +277,9 @@
schema:create-file-object-thumbnail
[:map {:title "create-file-object-thumbnail"}
[:file-id ::sm/uuid]
[:object-id :string]
[:object-id [:string {:max 250}]]
[:media ::media/upload]
[:tag {:optional true} :string]])
[:tag {:optional true} [:string {:max 50}]]])
(sv/defmethod ::create-file-object-thumbnail
{::doc/added "1.19"
@@ -298,9 +296,8 @@
(media/validate-media-size! media)
(db/run! cfg files/check-edition-permissions! profile-id file-id)
(let [cfg (update cfg ::sto/storage media/configure-assets-storage)]
(create-file-object-thumbnail! cfg file-id object-id media (or tag "frame"))))
(when-let [file (files/get-minimal-file cfg file-id {::db/check-deleted false})]
(create-file-object-thumbnail! cfg file object-id media (or tag "frame"))))
;; --- MUTATION COMMAND: delete-file-object-thumbnail
@@ -317,25 +314,23 @@
:object-id object-id
:tag tag})))
(s/def ::delete-file-object-thumbnail
(s/keys :req [::rpc/profile-id]
:req-un [::file-id ::object-id]))
(def ^:private schema:delete-file-object-thumbnail
[:map {:title "delete-file-object-thumbnail"}
[:file-id ::sm/uuid]
[:object-id [:string {:max 250}]]])
(sv/defmethod ::delete-file-object-thumbnail
{::doc/added "1.19"
::doc/module :files
::doc/deprecated "1.20"
::climit/id [[:file-thumbnail-ops/by-profile ::rpc/profile-id]
[:file-thumbnail-ops/global]]
::sm/params schema:delete-file-object-thumbnail
::audit/skip true}
[cfg {:keys [::rpc/profile-id file-id object-id]}]
(files/check-edition-permissions! cfg profile-id file-id)
(db/tx-run! cfg (fn [{:keys [::db/conn] :as cfg}]
(files/check-edition-permissions! conn profile-id file-id)
(when-not (db/read-only? conn)
(-> cfg
(update ::sto/storage media/configure-assets-storage conn)
(delete-file-object-thumbnail! file-id object-id))
nil))))
(-> cfg
(update ::sto/storage sto/configure conn)
(delete-file-object-thumbnail! file-id object-id))
nil)))
;; --- MUTATION COMMAND: create-file-thumbnail
@@ -392,7 +387,7 @@
schema:create-file-thumbnail
[:map {:title "create-file-thumbnail"}
[:file-id ::sm/uuid]
[:revn :int]
[:revn ::sm/int]
[:media ::media/upload]])
(sv/defmethod ::create-file-thumbnail
@@ -411,6 +406,6 @@
(db/tx-run! cfg (fn [{:keys [::db/conn] :as cfg}]
(files/check-edition-permissions! conn profile-id file-id)
(when-not (db/read-only? conn)
(let [cfg (update cfg ::sto/storage media/configure-assets-storage)
media (create-file-thumbnail! cfg params)]
{:uri (files/resolve-public-uri (:id media))})))))
(let [media (create-file-thumbnail! cfg params)]
{:uri (files/resolve-public-uri (:id media))
:id (:id media)})))))

View File

@@ -29,6 +29,7 @@
[app.rpc.commands.teams :as teams]
[app.rpc.doc :as-alias doc]
[app.rpc.helpers :as rph]
[app.storage :as sto]
[app.util.blob :as blob]
[app.util.pointer-map :as pmap]
[app.util.services :as sv]
@@ -37,6 +38,20 @@
[clojure.set :as set]
[promesa.exec :as px]))
(declare ^:private get-lagged-changes)
(declare ^:private send-notifications!)
(declare ^:private update-file)
(declare ^:private update-file*)
(declare ^:private process-changes-and-validate)
(declare ^:private take-snapshot?)
(declare ^:private delete-old-snapshots!)
;; PUBLIC API; intended to be used outside of this module
(declare update-file!)
(declare update-file-data!)
(declare persist-file!)
(declare get-file)
;; --- SCHEMA
(def ^:private
@@ -44,15 +59,15 @@
[:map {:title "update-file"}
[:id ::sm/uuid]
[:session-id ::sm/uuid]
[:revn {:min 0} :int]
[:revn {:min 0} ::sm/int]
[:features {:optional true} ::cfeat/features]
[:changes {:optional true} [:vector ::cpc/change]]
[:changes-with-metadata {:optional true}
[:vector [:map
[:changes [:vector ::cpc/change]]
[:hint-origin {:optional true} :keyword]
[:hint-events {:optional true} [:vector :string]]]]]
[:skip-validate {:optional true} :boolean]])
[:hint-events {:optional true} [:vector [:string {:max 250}]]]]]]
[:skip-validate {:optional true} ::sm/boolean]])
(def ^:private
schema:update-file-result
@@ -61,7 +76,7 @@
[:changes [:vector ::cpc/change]]
[:file-id ::sm/uuid]
[:id ::sm/uuid]
[:revn {:min 0} :int]
[:revn {:min 0} ::sm/int]
[:session-id ::sm/uuid]]])
;; --- HELPERS
@@ -96,40 +111,6 @@
(or (contains? library-change-types type)
(contains? file-change-types type)))
(def ^:private sql:get-file
"SELECT f.*, p.team_id
FROM file AS f
JOIN project AS p ON (p.id = f.project_id)
WHERE f.id = ?
AND (f.deleted_at IS NULL OR
f.deleted_at > now())
FOR KEY SHARE")
(defn get-file
[conn id]
(let [file (db/exec-one! conn [sql:get-file id])]
(when-not file
(ex/raise :type :not-found
:code :object-not-found
:hint (format "file with id '%s' does not exists" id)))
(update file :features db/decode-pgarray #{})))
(defn- wrap-with-pointer-map-context
[f]
(fn [cfg {:keys [id] :as file}]
(binding [pmap/*tracked* (pmap/create-tracked)
pmap/*load-fn* (partial feat.fdata/load-pointer cfg id)]
(let [result (f cfg file)]
(feat.fdata/persist-pointers! cfg id)
result))))
(declare get-lagged-changes)
(declare send-notifications!)
(declare update-file)
(declare update-file*)
(declare update-file-data)
(declare take-snapshot?)
;; If features are specified from params and the final feature
;; set is different than the persisted one, update it on the
;; database.
@@ -145,7 +126,8 @@
::sm/result schema:update-file-result
::doc/module :files
::doc/added "1.17"}
[cfg {:keys [::rpc/profile-id id] :as params}]
[{:keys [::mtx/metrics] :as cfg}
{:keys [::rpc/profile-id id changes changes-with-metadata] :as params}]
(db/tx-run! cfg (fn [{:keys [::db/conn] :as cfg}]
(files/check-edition-permissions! conn profile-id id)
(db/xact-lock! conn id)
@@ -159,14 +141,30 @@
(cfeat/check-client-features! (:features params))
(cfeat/check-file-features! (:features file) (:features params)))
params (assoc params
:profile-id profile-id
:features features
:team team
:file file)
changes (if changes-with-metadata
(->> changes-with-metadata (mapcat :changes) vec)
(vec changes))
params (-> params
(assoc :profile-id profile-id)
(assoc :features features)
(assoc :team team)
(assoc :file file)
(assoc :changes changes))
cfg (assoc cfg ::timestamp (dt/now))
tpoint (dt/tpoint)]
(when (> (:revn params)
(:revn file))
(ex/raise :type :validation
:code :revn-conflict
:hint "The incoming revision number is greater that stored version."
:context {:incoming-revn (:revn params)
:stored-revn (:revn file)}))
;; When newly computed features does not match exactly with
;; the features defined on team row, we update it.
(when (not= features (:features team))
@@ -175,73 +173,124 @@
{:features features}
{:id (:id team)})))
(mtx/run! metrics {:id :update-file-changes :inc (count changes)})
(binding [l/*context* (some-> (meta params)
(get :app.http/request)
(errors/request->context))]
(-> (update-file cfg params)
(-> (update-file* cfg params)
(rph/with-defer #(let [elapsed (tpoint)]
(l/trace :hint "update-file" :time (dt/format-duration elapsed))))))))))
(defn update-file
[{:keys [::mtx/metrics] :as cfg}
{:keys [file features changes changes-with-metadata] :as params}]
(let [features (-> features
(set/difference cfeat/frontend-only-features)
(set/union (:features file)))
update-fn (cond-> update-file*
(contains? features "fdata/pointer-map")
(wrap-with-pointer-map-context))
changes (if changes-with-metadata
(->> changes-with-metadata (mapcat :changes) vec)
(vec changes))]
(when (> (:revn params)
(:revn file))
(ex/raise :type :validation
:code :revn-conflict
:hint "The incoming revision number is greater that stored version."
:context {:incoming-revn (:revn params)
:stored-revn (:revn file)}))
(mtx/run! metrics {:id :update-file-changes :inc (count changes)})
(binding [cfeat/*current* features
cfeat/*previous* (:features file)]
(let [file (assoc file :features features)
params (-> params
(assoc :file file)
(assoc :changes changes)
(assoc ::created-at (dt/now)))]
(-> (update-fn cfg params)
(vary-meta assoc ::audit/replace-props
{:id (:id file)
:name (:name file)
:features (:features file)
:project-id (:project-id file)
:team-id (:team-id file)}))))))
(defn- update-file*
[{:keys [::db/conn ::wrk/executor] :as cfg}
{:keys [profile-id file changes session-id ::created-at skip-validate] :as params}]
(let [;; Process the file data on separated thread for avoid to do
;; the CPU intensive operation on vthread.
file (px/invoke! executor (partial update-file-data cfg file changes skip-validate))
features (db/create-array conn "text" (:features file))]
"Internal function, part of the update-file process, that encapsulates
the changes application offload to a separated thread and emit all
corresponding notifications.
(db/insert! conn :file-change
{:id (uuid/next)
:session-id session-id
:profile-id profile-id
:created-at created-at
:file-id (:id file)
:revn (:revn file)
:features (db/create-array conn "text" (:features file))
:data (when (take-snapshot? file)
(:data file))
:changes (blob/encode changes)}
Follow the inner implementation to `update-file-data!` function.
Only intended for internal use on this module."
[{:keys [::db/conn ::wrk/executor ::timestamp] :as cfg}
{:keys [profile-id file features changes session-id skip-validate] :as params}]
(let [;; Retrieve the file data
file (feat.fdata/resolve-file-data cfg file)
file (assoc file :features
(-> features
(set/difference cfeat/frontend-only-features)
(set/union (:features file))))
;; Process the file data on separated thread for avoid to do
;; the CPU intensive operation on vthread.
file (px/invoke! executor
(fn []
(binding [cfeat/*current* features
cfeat/*previous* (:features file)]
(update-file-data! cfg file
process-changes-and-validate
changes skip-validate))))]
(when (feat.fdata/offloaded? file)
(let [storage (sto/resolve cfg ::db/reuse-conn true)]
(some->> (:data-ref-id file) (sto/touch-object! storage))))
;; TODO: move this to asynchronous task
(when (::snapshot-data file)
(delete-old-snapshots! cfg file))
(persist-file! cfg file)
(let [params (assoc params :file file)
response {:revn (:revn file)
:lagged (get-lagged-changes conn params)}
features (db/create-array conn "text" (:features file))]
;; Insert change (xlog)
(db/insert! conn :file-change
{:id (uuid/next)
:session-id session-id
:profile-id profile-id
:created-at timestamp
:file-id (:id file)
:revn (:revn file)
:version (:version file)
:features features
:label (::snapshot-label file)
:data (::snapshot-data file)
:changes (blob/encode changes)}
{::db/return-keys false})
;; Send asynchronous notifications
(send-notifications! cfg params)
(vary-meta response assoc ::audit/replace-props
{:id (:id file)
:name (:name file)
:features (:features file)
:project-id (:project-id file)
:team-id (:team-id file)}))))
(defn update-file!
"A public api that allows apply a transformation to a file with all context setup."
[cfg file-id update-fn & args]
(let [file (get-file cfg file-id)
file (apply update-file-data! cfg file update-fn args)]
(persist-file! cfg file)))
(def ^:private sql:get-file
"SELECT f.*, p.team_id
FROM file AS f
JOIN project AS p ON (p.id = f.project_id)
WHERE f.id = ?
AND (f.deleted_at IS NULL OR
f.deleted_at > now())
FOR KEY SHARE")
(defn get-file
"Get not-decoded file, only decodes the features set."
[conn id]
(let [file (db/exec-one! conn [sql:get-file id])]
(when-not file
(ex/raise :type :not-found
:code :object-not-found
:hint (format "file with id '%s' does not exists" id)))
(update file :features db/decode-pgarray #{})))
(defn persist-file!
"Function responsible of persisting already encoded file. Should be
used together with `get-file` and `update-file-data!`.
It also updates the project modified-at attr."
[{:keys [::db/conn ::timestamp]} file]
(let [features (db/create-array conn "text" (:features file))
;; The timestamp can be nil because this function is also
;; intended to be used outside of this module
modified-at (or timestamp (dt/now))]
(db/update! conn :project
{:modified-at modified-at}
{:id (:project-id file)}
{::db/return-keys false})
(db/update! conn :file
@@ -250,20 +299,96 @@
:version (:version file)
:features features
:data-backend nil
:modified-at created-at
:data-ref-id nil
:modified-at modified-at
:has-media-trimmed false}
{:id (:id file)})
{:id (:id file)}
{::db/return-keys false})))
(db/update! conn :project
{:modified-at created-at}
{:id (:project-id file)})
(defn- update-file-data!
"Perform a file data transformation in with all update context setup.
(let [params (assoc params :file file)]
;; Send asynchronous notifications
(send-notifications! cfg params)
This function expected not-decoded file and transformation function. Returns
an encoded file.
;; Retrieve and return lagged data
(get-lagged-changes conn params))))
This function is not responsible of saving the file. It only saves
fdata/pointer-map modified fragments."
[cfg {:keys [id] :as file} update-fn & args]
(binding [pmap/*tracked* (pmap/create-tracked)
pmap/*load-fn* (partial feat.fdata/load-pointer cfg id)]
(let [file (update file :data (fn [data]
(-> data
(blob/decode)
(assoc :id (:id file)))))
;; For avoid unnecesary overhead of creating multiple pointers
;; and handly internally with objects map in their worst
;; case (when probably all shapes and all pointers will be
;; readed in any case), we just realize/resolve them before
;; applying the migration to the file
file (if (fmg/need-migration? file)
(-> file
(update :data feat.fdata/process-pointers deref)
(update :data feat.fdata/process-objects (partial into {}))
(fmg/migrate-file))
file)
file (apply update-fn cfg file args)
;; TODO: reuse operations if file is migrated
;; TODO: move encoding to a separated thread
file (if (take-snapshot? file)
(let [tpoint (dt/tpoint)
snapshot (-> (:data file)
(feat.fdata/process-pointers deref)
(feat.fdata/process-objects (partial into {}))
(blob/encode))
elapsed (tpoint)
label (str "internal/snapshot/" (:revn file))]
(l/trc :hint "take snapshot"
:file-id (str (:id file))
:revn (:revn file)
:label label
:elapsed (dt/format-duration elapsed))
(-> file
(assoc ::snapshot-data snapshot)
(assoc ::snapshot-label label)))
file)
file (cond-> file
(contains? cfeat/*current* "fdata/objects-map")
(feat.fdata/enable-objects-map)
(contains? cfeat/*current* "fdata/pointer-map")
(feat.fdata/enable-pointer-map)
:always
(update :data blob/encode))]
(feat.fdata/persist-pointers! cfg id)
file)))
(defn- get-file-libraries
"A helper for preload file libraries, mainly used for perform file
semantical and structural validation"
[{:keys [::db/conn] :as cfg} file]
(->> (files/get-file-libraries conn (:id file))
(into [file] (map (fn [{:keys [id]}]
(binding [pmap/*load-fn* (partial feat.fdata/load-pointer cfg id)
pmap/*tracked* nil]
;; We do not resolve the objects maps here
;; because there is a lower probability that all
;; shapes needed to be loded into memory, so we
;; leeave it on lazy status
(-> (files/get-file cfg id :migrate? false)
(update :data feat.fdata/process-pointers deref) ; ensure all pointers resolved
(update :data feat.fdata/process-objects (partial into {}))
(fmg/migrate-file))))))
(d/index-by :id)))
(defn- soft-validate-file-schema!
[file]
@@ -280,87 +405,78 @@
(l/error :hint "file validation error"
:cause cause))))
(defn- update-file-data
[{:keys [::db/conn] :as cfg} file changes skip-validate]
(let [file (update file :data (fn [data]
(-> data
(blob/decode)
(assoc :id (:id file)))))
;; For avoid unnecesary overhead of creating multiple pointers
;; and handly internally with objects map in their worst
;; case (when probably all shapes and all pointers will be
;; readed in any case), we just realize/resolve them before
;; applying the migration to the file
file (if (fmg/need-migration? file)
(-> file
(update :data feat.fdata/process-pointers deref)
(update :data feat.fdata/process-objects (partial into {}))
(fmg/migrate-file))
file)
;; WARNING: this ruins performance; maybe we need to find
(defn- process-changes-and-validate
[cfg file changes skip-validate]
(let [;; WARNING: this ruins performance; maybe we need to find
;; some other way to do general validation
libs (when (and (or (contains? cf/flags :file-validation)
(contains? cf/flags :soft-file-validation))
(not skip-validate))
(->> (files/get-file-libraries conn (:id file))
(into [file] (map (fn [{:keys [id]}]
(binding [pmap/*load-fn* (partial feat.fdata/load-pointer cfg id)
pmap/*tracked* nil]
;; We do not resolve the objects maps here
;; because there is a lower probability that all
;; shapes needed to be loded into memory, so we
;; leeave it on lazy status
(-> (files/get-file cfg id :migrate? false)
(update :data feat.fdata/process-pointers deref) ; ensure all pointers resolved
(update :data feat.fdata/process-objects (partial into {}))
(fmg/migrate-file))))))
(d/index-by :id)))
(get-file-libraries cfg file))
file (-> (files/check-version! file)
(update :revn inc)
(update :data cpc/process-changes changes)
(update :data d/without-nils))]
(when (contains? cf/flags :soft-file-validation)
(soft-validate-file! file libs))
(binding [pmap/*tracked* nil]
(when (contains? cf/flags :soft-file-validation)
(soft-validate-file! file libs))
(when (contains? cf/flags :soft-file-schema-validation)
(soft-validate-file-schema! file))
(when (contains? cf/flags :soft-file-schema-validation)
(soft-validate-file-schema! file))
(when (and (contains? cf/flags :file-validation)
(not skip-validate))
(val/validate-file! file libs))
(when (and (contains? cf/flags :file-validation)
(not skip-validate))
(val/validate-file! file libs))
(when (and (contains? cf/flags :file-schema-validation)
(not skip-validate))
(val/validate-file-schema! file))
(when (and (contains? cf/flags :file-schema-validation)
(not skip-validate))
(val/validate-file-schema! file)))
(cond-> file
(contains? cfeat/*current* "fdata/objects-map")
(feat.fdata/enable-objects-map)
(contains? cfeat/*current* "fdata/pointer-map")
(feat.fdata/enable-pointer-map)
:always
(update :data blob/encode))))
file))
(defn- take-snapshot?
"Defines the rule when file `data` snapshot should be saved."
[{:keys [revn modified-at] :as file}]
(let [freq (or (cf/get :file-change-snapshot-every) 20)
timeout (or (cf/get :file-change-snapshot-timeout)
(dt/duration {:hours 1}))]
(or (= 1 freq)
(zero? (mod revn freq))
(> (inst-ms (dt/diff modified-at (dt/now)))
(inst-ms timeout)))))
(when (contains? cf/flags :auto-file-snapshot)
(let [freq (or (cf/get :auto-file-snapshot-every) 20)
timeout (or (cf/get :auto-file-snapshot-timeout)
(dt/duration {:hours 1}))]
(def ^:private
sql:lagged-changes
(or (= 1 freq)
(zero? (mod revn freq))
(> (inst-ms (dt/diff modified-at (dt/now)))
(inst-ms timeout))))))
;; Get the latest available snapshots without exceeding the total
;; snapshot limit.
(def ^:private sql:get-latest-snapshots
"SELECT fch.id, fch.created_at
FROM file_change AS fch
WHERE fch.file_id = ?
AND fch.label LIKE 'internal/%'
ORDER BY fch.created_at DESC
LIMIT ?")
;; Mark all snapshots that are outside the allowed total threshold
;; available for the GC.
(def ^:private sql:delete-snapshots
"UPDATE file_change
SET label = NULL
WHERE file_id = ?
AND label LIKE 'internal/%'
AND created_at < ?")
(defn- delete-old-snapshots!
[{:keys [::db/conn] :as cfg} {:keys [id] :as file}]
(when-let [snapshots (not-empty (db/exec! conn [sql:get-latest-snapshots id
(cf/get :auto-file-snapshot-total 10)]))]
(let [last-date (-> snapshots peek :created-at)
result (db/exec-one! conn [sql:delete-snapshots id last-date])]
(l/trc :hint "delete old snapshots" :file-id (str id) :total (db/get-update-count result)))))
(def ^:private sql:lagged-changes
"select s.id, s.revn, s.file_id,
s.session_id, s.changes
from file_change as s

View File

@@ -95,12 +95,11 @@
[cfg {:keys [::rpc/profile-id team-id] :as params}]
(db/tx-run! cfg
(fn [{:keys [::db/conn] :as cfg}]
(let [cfg (update cfg ::sto/storage media/configure-assets-storage)]
(teams/check-edition-permissions! conn profile-id team-id)
(quotes/check-quote! conn {::quotes/id ::quotes/font-variants-per-team
::quotes/profile-id profile-id
::quotes/team-id team-id})
(create-font-variant cfg (assoc params :profile-id profile-id))))))
(teams/check-edition-permissions! conn profile-id team-id)
(quotes/check-quote! conn {::quotes/id ::quotes/font-variants-per-team
::quotes/profile-id profile-id
::quotes/team-id team-id})
(create-font-variant cfg (assoc params :profile-id profile-id)))))
(defn create-font-variant
[{:keys [::sto/storage ::db/conn ::wrk/executor]} {:keys [data] :as params}]
@@ -203,14 +202,13 @@
::sm/params schema:delete-font}
[cfg {:keys [::rpc/profile-id id team-id]}]
(db/tx-run! cfg
(fn [{:keys [::db/conn ::sto/storage] :as cfg}]
(fn [{:keys [::db/conn] :as cfg}]
(teams/check-edition-permissions! conn profile-id team-id)
(let [fonts (db/query conn :team-font-variant
{:team-id team-id
:font-id id
:deleted-at nil}
{::sql/for-update true})
storage (media/configure-assets-storage storage conn)
tnow (dt/now)]
(when-not (seq fonts)
@@ -220,11 +218,7 @@
(doseq [font fonts]
(db/update! conn :team-font-variant
{:deleted-at tnow}
{:id (:id font)})
(some->> (:woff1-file-id font) (sto/touch-object! storage))
(some->> (:woff2-file-id font) (sto/touch-object! storage))
(some->> (:ttf-file-id font) (sto/touch-object! storage))
(some->> (:otf-file-id font) (sto/touch-object! storage)))
{:id (:id font)}))
(rph/with-meta (rph/wrap)
{::audit/props {:id id
@@ -245,22 +239,16 @@
::sm/params schema:delete-font-variant}
[cfg {:keys [::rpc/profile-id id team-id]}]
(db/tx-run! cfg
(fn [{:keys [::db/conn ::sto/storage] :as cfg}]
(fn [{:keys [::db/conn] :as cfg}]
(teams/check-edition-permissions! conn profile-id team-id)
(let [variant (db/get conn :team-font-variant
{:id id :team-id team-id}
{::sql/for-update true})
storage (media/configure-assets-storage storage conn)]
{::sql/for-update true})]
(db/update! conn :team-font-variant
{:deleted-at (dt/now)}
{:id (:id variant)})
(some->> (:woff1-file-id variant) (sto/touch-object! storage))
(some->> (:woff2-file-id variant) (sto/touch-object! storage))
(some->> (:ttf-file-id variant) (sto/touch-object! storage))
(some->> (:otf-file-id variant) (sto/touch-object! storage))
(rph/with-meta (rph/wrap)
{::audit/props {:font-family (:font-family variant)
:font-id (:font-id variant)}})))))

View File

@@ -8,11 +8,10 @@
(:require
[app.auth.ldap :as ldap]
[app.common.exceptions :as ex]
[app.common.spec :as us]
[app.common.schema :as sm]
[app.db :as db]
[app.http.session :as session]
[app.loggers.audit :as-alias audit]
[app.main :as-alias main]
[app.rpc :as-alias rpc]
[app.rpc.commands.auth :as auth]
[app.rpc.commands.profile :as profile]
@@ -20,27 +19,25 @@
[app.rpc.helpers :as rph]
[app.setup :as-alias setup]
[app.tokens :as tokens]
[app.util.services :as sv]
[clojure.spec.alpha :as s]))
[app.util.services :as sv]))
;; --- COMMAND: login-with-ldap
(declare login-or-register)
(s/def ::email ::us/email)
(s/def ::password ::us/string)
(s/def ::invitation-token ::us/string)
(s/def ::login-with-ldap
(s/keys :req-un [::email ::password]
:opt-un [::invitation-token]))
(def schema:login-with-ldap
[:map {:title "login-with-ldap"}
[:email ::sm/email]
[:password auth/schema:password]
[:invitation-token {:optional true} auth/schema:token]])
(sv/defmethod ::login-with-ldap
"Performs the authentication using LDAP backend. Only works if LDAP
is properly configured and enabled with `login-with-ldap` flag."
{::rpc/auth false
::doc/added "1.15"
::doc/module :auth}
::doc/module :auth
::sm/params schema:login-with-ldap}
[{:keys [::setup/props ::ldap/provider] :as cfg} params]
(when-not provider
(ex/raise :type :restriction
@@ -73,7 +70,7 @@
(rph/with-meta {::audit/props (:props profile)
::audit/profile-id (:id profile)})))
(-> profile
(-> (profile/strip-private-attrs profile)
(rph/with-transform (session/create-fn cfg (:id profile)))
(rph/with-meta {::audit/props (:props profile)
::audit/profile-id (:id profile)}))))))

View File

@@ -16,6 +16,7 @@
[app.config :as cf]
[app.db :as db]
[app.http.sse :as sse]
[app.loggers.audit :as audit]
[app.loggers.webhooks :as-alias webhooks]
[app.rpc :as-alias rpc]
[app.rpc.commands.files :as files]
@@ -90,7 +91,7 @@
(sm/define
[:map {:title "duplicate-file"}
[:file-id ::sm/uuid]
[:name {:optional true} :string]]))
[:name {:optional true} [:string {:max 250}]]]))
(sv/defmethod ::duplicate-file
"Duplicate a single file in the same team."
@@ -152,7 +153,7 @@
(sm/define
[:map {:title "duplicate-project"}
[:project-id ::sm/uuid]
[:name {:optional true} :string]]))
[:name {:optional true} [:string {:max 250}]]]))
(sv/defmethod ::duplicate-project
"Duplicate an entire project with all the files"
@@ -381,10 +382,9 @@
(def ^:private
schema:move-project
(sm/define
[:map {:title "move-project"}
[:team-id ::sm/uuid]
[:project-id ::sm/uuid]]))
[:map {:title "move-project"}
[:team-id ::sm/uuid]
[:project-id ::sm/uuid]])
(sv/defmethod ::move-project
"Move projects between teams"
@@ -396,25 +396,38 @@
;; --- COMMAND: Clone Template
(defn- clone-template
[{:keys [::wrk/executor ::bf.v1/project-id] :as cfg} template]
(db/tx-run! cfg (fn [{:keys [::db/conn] :as cfg}]
(defn clone-template
[cfg {:keys [project-id profile-id] :as params} template]
(db/tx-run! cfg (fn [{:keys [::db/conn ::wrk/executor] :as cfg}]
;; NOTE: the importation process performs some operations that
;; are not very friendly with virtual threads, and for avoid
;; unexpected blocking of other concurrent operations we
;; dispatch that operation to a dedicated executor.
(let [result (px/submit! executor (partial bf.v1/import-files! cfg template))]
(let [cfg (-> cfg
(assoc ::bf.v1/project-id project-id)
(assoc ::bf.v1/profile-id profile-id))
result (px/invoke! executor (partial bf.v1/import-files! cfg template))]
(db/update! conn :project
{:modified-at (dt/now)}
{:id project-id})
(deref result)))))
(let [props (audit/clean-props params)]
(doseq [file-id result]
(let [props (assoc props :id file-id)
event (-> (audit/event-from-rpc-params params)
(assoc ::audit/profile-id profile-id)
(assoc ::audit/name "create-file")
(assoc ::audit/props props))]
(audit/submit! cfg event))))
result))))
(def ^:private
schema:clone-template
(sm/define
[:map {:title "clone-template"}
[:project-id ::sm/uuid]
[:template-id ::sm/word-string]]))
[:map {:title "clone-template"}
[:project-id ::sm/uuid]
[:template-id ::sm/word-string]])
(sv/defmethod ::clone-template
"Clone into the specified project the template by its id."
@@ -426,15 +439,14 @@
(let [project (db/get-by-id pool :project project-id {:columns [:id :team-id]})
_ (teams/check-edition-permissions! pool profile-id (:team-id project))
template (tmpl/get-template-stream cfg template-id)
params (-> cfg
(assoc ::bf.v1/project-id (:id project))
(assoc ::bf.v1/profile-id profile-id))]
params (assoc params :profile-id profile-id)]
(when-not template
(ex/raise :type :not-found
:code :template-not-found
:hint "template not found"))
(sse/response #(clone-template params template))))
(sse/response #(clone-template cfg params template))))
;; --- COMMAND: Get list of builtin templates

View File

@@ -9,7 +9,7 @@
[app.common.data :as d]
[app.common.exceptions :as ex]
[app.common.media :as cm]
[app.common.spec :as us]
[app.common.schema :as sm]
[app.common.uuid :as uuid]
[app.config :as cf]
[app.db :as db]
@@ -25,7 +25,6 @@
[app.util.services :as sv]
[app.util.time :as dt]
[app.worker :as-alias wrk]
[clojure.spec.alpha :as s]
[cuerdas.core :as str]
[datoteka.io :as io]
[promesa.exec :as px]))
@@ -39,43 +38,37 @@
:quality 85
:format :jpeg})
(s/def ::id ::us/uuid)
(s/def ::name ::us/string)
(s/def ::file-id ::us/uuid)
(s/def ::team-id ::us/uuid)
;; --- Create File Media object (upload)
(declare create-file-media-object)
(s/def ::content ::media/upload)
(s/def ::is-local ::us/boolean)
(s/def ::upload-file-media-object
(s/keys :req [::rpc/profile-id]
:req-un [::file-id ::is-local ::name ::content]
:opt-un [::id]))
(def ^:private schema:upload-file-media-object
[:map {:title "upload-file-media-object"}
[:id {:optional true} ::sm/uuid]
[:file-id ::sm/uuid]
[:is-local ::sm/boolean]
[:name [:string {:max 250}]]
[:content ::media/upload]])
(sv/defmethod ::upload-file-media-object
{::doc/added "1.17"
::sm/params schema:upload-file-media-object
::climit/id [[:process-image/by-profile ::rpc/profile-id]
[:process-image/global]]}
[{:keys [::db/pool] :as cfg} {:keys [::rpc/profile-id file-id content] :as params}]
(let [cfg (update cfg ::sto/storage media/configure-assets-storage)]
(files/check-edition-permissions! pool profile-id file-id)
(media/validate-media-type! content)
(media/validate-media-size! content)
(files/check-edition-permissions! pool profile-id file-id)
(media/validate-media-type! content)
(media/validate-media-size! content)
(db/run! cfg (fn [cfg]
(let [object (create-file-media-object cfg params)
props {:name (:name params)
:file-id file-id
:is-local (:is-local params)
:size (:size content)
:mtype (:mtype content)}]
(with-meta object
{::audit/replace-props props}))))))
(db/run! cfg (fn [cfg]
(let [object (create-file-media-object cfg params)
props {:name (:name params)
:file-id file-id
:is-local (:is-local params)
:size (:size content)
:mtype (:mtype content)}]
(with-meta object
{::audit/replace-props props})))))
(defn- big-enough-for-thumbnail?
"Checks if the provided image info is big enough for
@@ -176,18 +169,20 @@
(declare ^:private create-file-media-object-from-url)
(s/def ::create-file-media-object-from-url
(s/keys :req [::rpc/profile-id]
:req-un [::file-id ::is-local ::url]
:opt-un [::id ::name]))
(def ^:private schema:create-file-media-object-from-url
[:map {:title "create-file-media-object-from-url"}
[:file-id ::sm/uuid]
[:is-local ::sm/boolean]
[:url ::sm/uri]
[:id {:optional true} ::sm/uuid]
[:name {:optional true} [:string {:max 250}]]])
(sv/defmethod ::create-file-media-object-from-url
{::doc/added "1.17"
::doc/deprecated "1.19"}
::sm/params schema:create-file-media-object-from-url}
[{:keys [::db/pool] :as cfg} {:keys [::rpc/profile-id file-id] :as params}]
(let [cfg (update cfg ::sto/storage media/configure-assets-storage)]
(files/check-edition-permissions! pool profile-id file-id)
(create-file-media-object-from-url cfg (assoc params :profile-id profile-id))))
(files/check-edition-permissions! pool profile-id file-id)
(create-file-media-object-from-url cfg (assoc params :profile-id profile-id)))
(defn download-image
[{:keys [::http/client]} uri]
@@ -255,12 +250,15 @@
(declare clone-file-media-object)
(s/def ::clone-file-media-object
(s/keys :req [::rpc/profile-id]
:req-un [::file-id ::is-local ::id]))
(def ^:private schema:clone-file-media-object
[:map {:title "clone-file-media-object"}
[:file-id ::sm/uuid]
[:is-local ::sm/boolean]
[:id ::sm/uuid]])
(sv/defmethod ::clone-file-media-object
{::doc/added "1.17"}
{::doc/added "1.17"
::sm/params schema:clone-file-media-object}
[{:keys [::db/pool] :as cfg} {:keys [::rpc/profile-id file-id] :as params}]
(db/with-atomic [conn pool]
(files/check-edition-permissions! conn profile-id file-id)

View File

@@ -28,7 +28,7 @@
[app.tokens :as tokens]
[app.util.services :as sv]
[app.util.time :as dt]
[app.worker :as-alias wrk]
[app.worker :as wrk]
[cuerdas.core :as str]
[promesa.exec :as px]))
@@ -46,6 +46,10 @@
(let [email (str/lower email)
email (if (str/starts-with? email "mailto:")
(subs email 7)
email)
email (if (or (str/starts-with? email "<")
(str/ends-with? email ">"))
(str/trim email "<>")
email)]
email))
@@ -56,10 +60,10 @@
[:id ::sm/uuid]
[:fullname [::sm/word-string {:max 250}]]
[:email ::sm/email]
[:is-active {:optional true} :boolean]
[:is-blocked {:optional true} :boolean]
[:is-demo {:optional true} :boolean]
[:is-muted {:optional true} :boolean]
[:is-active {:optional true} ::sm/boolean]
[:is-blocked {:optional true} ::sm/boolean]
[:is-demo {:optional true} ::sm/boolean]
[:is-muted {:optional true} ::sm/boolean]
[:created-at {:optional true} ::sm/inst]
[:modified-at {:optional true} ::sm/inst]
[:default-project-id {:optional true} ::sm/uuid]
@@ -87,8 +91,8 @@
(defn get-profile
"Get profile by id. Throws not-found exception if no profile found."
[conn id & {:as attrs}]
(-> (db/get-by-id conn :profile id attrs)
[conn id & {:as opts}]
(-> (db/get-by-id conn :profile id opts)
(decode-row)))
;; --- MUTATION: Update Profile (own)
@@ -98,7 +102,7 @@
(sm/define
[:map {:title "update-profile"}
[:fullname [::sm/word-string {:max 250}]]
[:lang {:optional true} [:string {:max 5}]]
[:lang {:optional true} [:string {:max 8}]]
[:theme {:optional true} [:string {:max 250}]]]))
(sv/defmethod ::update-profile
@@ -106,7 +110,6 @@
::sm/params schema:update-profile
::sm/result schema:profile}
[{:keys [::db/pool] :as cfg} {:keys [::rpc/profile-id fullname lang theme] :as params}]
(db/with-atomic [conn pool]
;; NOTE: we need to retrieve the profile independently if we use
;; it or not for explicit locking and avoid concurrent updates of
@@ -207,8 +210,7 @@
[cfg {:keys [::rpc/profile-id file] :as params}]
;; Validate incoming mime type
(media/validate-media-type! file #{"image/jpeg" "image/png" "image/webp"})
(let [cfg (update cfg ::sto/storage media/configure-assets-storage)]
(update-profile-photo cfg (assoc params :profile-id profile-id))))
(update-profile-photo cfg (assoc params :profile-id profile-id)))
(defn update-profile-photo
[{:keys [::db/pool ::sto/storage] :as cfg} {:keys [profile-id file] :as params}]
@@ -273,19 +275,19 @@
(sv/defmethod ::request-email-change
{::doc/added "1.0"
::sm/params schema:request-email-change}
[{:keys [::db/pool] :as cfg} {:keys [::rpc/profile-id email] :as params}]
(db/with-atomic [conn pool]
(let [profile (db/get-by-id conn :profile profile-id)
cfg (assoc cfg ::conn conn)
params (assoc params
:profile profile
:email (clean-email email))]
(if (contains? cf/flags :smtp)
(request-email-change! cfg params)
(change-email-immediately! cfg params)))))
[cfg {:keys [::rpc/profile-id email] :as params}]
(db/tx-run! cfg
(fn [cfg]
(let [profile (db/get-by-id cfg :profile profile-id)
params (assoc params
:profile profile
:email (clean-email email))]
(if (contains? cf/flags :smtp)
(request-email-change! cfg params)
(change-email-immediately! cfg params))))))
(defn- change-email-immediately!
[{:keys [::conn]} {:keys [profile email] :as params}]
[{:keys [::db/conn]} {:keys [profile email] :as params}]
(when (not= email (:email profile))
(check-profile-existence! conn params))
@@ -296,7 +298,7 @@
{:changed true})
(defn- request-email-change!
[{:keys [::conn] :as cfg} {:keys [profile email] :as params}]
[{:keys [::db/conn] :as cfg} {:keys [profile email] :as params}]
(let [token (tokens/generate (::setup/props cfg)
{:iss :change-email
:exp (dt/in-future "15m")
@@ -316,9 +318,28 @@
:hint "looks like the profile has reported repeatedly as spam or has permanent bounces."))
(when (eml/has-bounce-reports? conn email)
(ex/raise :type :validation
(ex/raise :type :restriction
:code :email-has-permanent-bounces
:hint "looks like the email you invite has been repeatedly reported as spam or permanent bounce"))
:email email
:hint "looks like the email has bounce reports"))
(when (eml/has-complaint-reports? conn email)
(ex/raise :type :restriction
:code :email-has-complaints
:email email
:hint "looks like the email has spam complaint reports"))
(when (eml/has-bounce-reports? conn (:email profile))
(ex/raise :type :restriction
:code :email-has-permanent-bounces
:email (:email profile)
:hint "looks like the email has bounce reports"))
(when (eml/has-complaint-reports? conn (:email profile))
(ex/raise :type :restriction
:code :email-has-complaints
:email (:email profile)
:hint "looks like the email has spam complaint reports"))
(eml/send! {::eml/conn conn
::eml/factory eml/change-email
@@ -339,37 +360,41 @@
[:map {:title "update-profile-props"}
[:props [:map-of :keyword :any]]]))
(defn update-profile-props
[{:keys [::db/conn] :as cfg} profile-id props]
(let [profile (get-profile conn profile-id ::sql/for-update true)
props (reduce-kv (fn [props k v]
;; We don't accept namespaced keys
(if (simple-ident? k)
(if (nil? v)
(dissoc props k)
(assoc props k v))
props))
(:props profile)
props)]
(db/update! conn :profile
{:props (db/tjson props)}
{:id profile-id})
(filter-props props)))
(sv/defmethod ::update-profile-props
{::doc/added "1.0"
::sm/params schema:update-profile-props}
[{:keys [::db/pool]} {:keys [::rpc/profile-id props]}]
(db/with-atomic [conn pool]
(let [profile (get-profile conn profile-id ::sql/for-update true)
props (reduce-kv (fn [props k v]
;; We don't accept namespaced keys
(if (simple-ident? k)
(if (nil? v)
(dissoc props k)
(assoc props k v))
props))
(:props profile)
props)]
(db/update! conn :profile
{:props (db/tjson props)}
{:id profile-id})
(filter-props props))))
[cfg {:keys [::rpc/profile-id props]}]
(db/tx-run! cfg (fn [cfg]
(update-profile-props cfg profile-id props))))
;; --- MUTATION: Delete Profile
(declare ^:private get-owned-teams-with-participants)
(declare ^:private get-owned-teams)
(sv/defmethod ::delete-profile
{::doc/added "1.0"}
[{:keys [::db/pool] :as cfg} {:keys [::rpc/profile-id] :as params}]
(db/with-atomic [conn pool]
(let [teams (get-owned-teams-with-participants conn profile-id)
(let [teams (get-owned-teams conn profile-id)
deleted-at (dt/now)]
;; If we found owned teams with participants, we don't allow
@@ -381,37 +406,39 @@
:hint "The user need to transfer ownership of owned teams."
:context {:teams (mapv :id teams)}))
(doseq [{:keys [id]} teams]
(db/update! conn :team
{:deleted-at deleted-at}
{:id id}))
;; Mark profile deleted immediatelly
(db/update! conn :profile
{:deleted-at deleted-at}
{:id profile-id})
;; Schedule cascade deletion to a worker
(wrk/submit! {::db/conn conn
::wrk/task :delete-object
::wrk/params {:object :profile
:deleted-at deleted-at
:id profile-id}})
(rph/with-transform {} (session/delete-fn cfg)))))
;; --- HELPERS
(def sql:owned-teams
"with owner_teams as (
select tpr.team_id as id
from team_profile_rel as tpr
where tpr.is_owner is true
and tpr.profile_id = ?
"WITH owner_teams AS (
SELECT tpr.team_id AS id
FROM team_profile_rel AS tpr
WHERE tpr.is_owner IS TRUE
AND tpr.profile_id = ?
)
select tpr.team_id as id,
count(tpr.profile_id) - 1 as participants
from team_profile_rel as tpr
where tpr.team_id in (select id from owner_teams)
and tpr.profile_id != ?
group by 1")
SELECT tpr.team_id AS id,
count(tpr.profile_id) - 1 AS participants
FROM team_profile_rel AS tpr
WHERE tpr.team_id IN (SELECT id from owner_teams)
GROUP BY 1")
(defn- get-owned-teams-with-participants
(defn get-owned-teams
[conn profile-id]
(db/exec! conn [sql:owned-teams profile-id profile-id]))
(db/exec! conn [sql:owned-teams profile-id]))
(def ^:private sql:profile-existence
"select exists (select * from profile

View File

@@ -7,7 +7,8 @@
(ns app.rpc.commands.projects
(:require
[app.common.data.macros :as dm]
[app.common.spec :as us]
[app.common.exceptions :as ex]
[app.common.schema :as sm]
[app.db :as db]
[app.db.sql :as-alias sql]
[app.loggers.audit :as-alias audit]
@@ -20,10 +21,7 @@
[app.rpc.quotes :as quotes]
[app.util.services :as sv]
[app.util.time :as dt]
[clojure.spec.alpha :as s]))
(s/def ::id ::us/uuid)
(s/def ::name ::us/string)
[app.worker :as wrk]))
;; --- Check Project Permissions
@@ -73,13 +71,13 @@
(declare get-projects)
(s/def ::team-id ::us/uuid)
(s/def ::get-projects
(s/keys :req [::rpc/profile-id]
:req-un [::team-id]))
(def ^:private schema:get-projects
[:map {:title "get-projects"}
[:team-id ::sm/uuid]])
(sv/defmethod ::get-projects
{::doc/added "1.18"}
{::doc/added "1.18"
::sm/params schema:get-projects}
[{:keys [::db/pool]} {:keys [::rpc/profile-id team-id]}]
(dm/with-open [conn (db/open pool)]
(teams/check-read-permissions! conn profile-id team-id)
@@ -110,11 +108,12 @@
(declare get-all-projects)
(s/def ::get-all-projects
(s/keys :req [::rpc/profile-id]))
(def ^:private schema:get-all-projects
[:map {:title "get-all-projects"}])
(sv/defmethod ::get-all-projects
{::doc/added "1.18"}
{::doc/added "1.18"
::sm/params schema:get-all-projects}
[{:keys [::db/pool]} {:keys [::rpc/profile-id]}]
(dm/with-open [conn (db/open pool)]
(get-all-projects conn profile-id)))
@@ -152,12 +151,13 @@
;; --- QUERY: Get project
(s/def ::get-project
(s/keys :req [::rpc/profile-id]
:req-un [::id]))
(def ^:private schema:get-project
[:map {:title "get-project"}
[:id ::sm/uuid]])
(sv/defmethod ::get-project
{::doc/added "1.18"}
{::doc/added "1.18"
::sm/params schema:get-project}
[{:keys [::db/pool]} {:keys [::rpc/profile-id id]}]
(dm/with-open [conn (db/open pool)]
(let [project (db/get-by-id conn :project id)]
@@ -168,14 +168,16 @@
;; --- MUTATION: Create Project
(s/def ::create-project
(s/keys :req [::rpc/profile-id]
:req-un [::team-id ::name]
:opt-un [::id]))
(def ^:private schema:create-project
[:map {:title "create-project"}
[:team-id ::sm/uuid]
[:name [:string {:max 250 :min 1}]]
[:id {:optional true} ::sm/uuid]])
(sv/defmethod ::create-project
{::doc/added "1.18"
::webhooks/event? true}
::webhooks/event? true
::sm/params schema:create-project}
[{:keys [::db/pool] :as cfg} {:keys [::rpc/profile-id team-id] :as params}]
(db/with-atomic [conn pool]
(teams/check-edition-permissions! conn profile-id team-id)
@@ -203,14 +205,15 @@
on conflict (team_id, project_id, profile_id)
do update set is_pinned=?")
(s/def ::is-pinned ::us/boolean)
(s/def ::project-id ::us/uuid)
(s/def ::update-project-pin
(s/keys :req [::rpc/profile-id]
:req-un [::id ::team-id ::is-pinned]))
(def ^:private schema:update-project-pin
[:map {:title "update-project-pin"}
[:team-id ::sm/uuid]
[:is-pinned ::sm/boolean]
[:id ::sm/uuid]])
(sv/defmethod ::update-project-pin
{::doc/added "1.18"
::sm/params schema:update-project-pin
::webhooks/batch-timeout (dt/duration "5s")
::webhooks/batch-key (webhooks/key-fn ::rpc/profile-id :id)
::webhooks/event? true}
@@ -224,12 +227,14 @@
(declare rename-project)
(s/def ::rename-project
(s/keys :req [::rpc/profile-id]
:req-un [::name ::id]))
(def ^:private schema:rename-project
[:map {:title "rename-project"}
[:name [:string {:max 250 :min 1}]]
[:id ::sm/uuid]])
(sv/defmethod ::rename-project
{::doc/added "1.18"
::sm/params schema:rename-project
::webhooks/event? true}
[{:keys [::db/pool] :as cfg} {:keys [::rpc/profile-id id name] :as params}]
(db/with-atomic [conn pool]
@@ -244,28 +249,41 @@
;; --- MUTATION: Delete Project
(s/def ::delete-project
(s/keys :req [::rpc/profile-id]
:req-un [::id]))
(defn- delete-project
[conn project-id]
(let [project (db/update! conn :project
{:deleted-at (dt/now)}
{:id project-id}
{::db/return-keys true})]
;; TODO: right now, we just don't allow delete default projects, in a
;; future we need to ensure raise a correct exception signaling that
;; this is not allowed.
(when (:is-default project)
(ex/raise :type :validation
:code :non-deletable-project
:hint "impossible to delete default project"))
(wrk/submit! {::db/conn conn
::wrk/task :delete-object
::wrk/params {:object :project
:deleted-at (:deleted-at project)
:id project-id}})
project))
(def ^:private schema:delete-project
[:map {:title "delete-project"}
[:id ::sm/uuid]])
(sv/defmethod ::delete-project
{::doc/added "1.18"
::sm/params schema:delete-project
::webhooks/event? true}
[{:keys [::db/pool] :as cfg} {:keys [::rpc/profile-id id] :as params}]
(db/with-atomic [conn pool]
(check-edition-permissions! conn profile-id id)
(let [project (db/update! conn :project
{:deleted-at (dt/now)}
{:id id :is-default false}
{::db/return-keys true})]
(let [project (delete-project conn id)]
(rph/with-meta (rph/wrap)
{::audit/props {:team-id (:team-id project)
:name (:name project)
:created-at (:created-at project)
:modified-at (:modified-at project)}}))))

Some files were not shown because too many files have changed in this diff Show More