mirror of
https://github.com/siyuan-note/siyuan.git
synced 2025-05-16 00:50:56 +08:00
Improve adaptive width for Attributes View
(#9280)
* 🎨 Attrs View adaptive width * 🎨 Add CSS class `av__body` * 🎨 add margins for attribute view * 🎨 add max-width for attribute view * Squashed commit of the following: commit642d041513
Author: Daniel <845765@qq.com> Date: Tue Oct 3 13:36:25 2023 +0800 🔖 Release v2.10.8 commit43e53672b0
Merge:6b0f8e00a
0e3b78020
Author: Vanessa <lly219@gmail.com> Date: Tue Oct 3 13:28:32 2023 +0800 Merge remote-tracking branch 'origin/dev' into dev commit6b0f8e00a8
Author: Vanessa <lly219@gmail.com> Date: Tue Oct 3 13:28:08 2023 +0800 🎨 fix https://github.com/siyuan-note/siyuan/issues/9334 commit0e3b780201
Author: Daniel <845765@qq.com> Date: Tue Oct 3 13:03:48 2023 +0800 📝 Update changelogs commitcc3b4e320e
Author: Daniel <845765@qq.com> Date: Tue Oct 3 13:01:11 2023 +0800 🎨 Database template column support using values from other columns https://github.com/siyuan-note/siyuan/issues/9327 commit29f34fe8b8
Author: Daniel <845765@qq.com> Date: Tue Oct 3 12:56:13 2023 +0800 🎨 Database template column support using values from other columns https://github.com/siyuan-note/siyuan/issues/9327 commit7556d1c3a2
Author: Daniel <845765@qq.com> Date: Tue Oct 3 11:49:12 2023 +0800 🎨 Database template column support using values from other columns https://github.com/siyuan-note/siyuan/issues/9327 commit558422c407
Author: Daniel <845765@qq.com> Date: Tue Oct 3 11:46:25 2023 +0800 🎨 Database template column support using values from other columns https://github.com/siyuan-note/siyuan/issues/9327 commit433cb91d75
Author: Daniel <845765@qq.com> Date: Tue Oct 3 10:33:41 2023 +0800 ⬆️ Upgrade kernel deps commitc5a25fe88f
Author: Daniel <845765@qq.com> Date: Tue Oct 3 08:52:33 2023 +0800 🐛 Database render deleted block https://ld246.com/article/1695790906050/comment/1696234209062?r=88250#comments commitf6a8ca20cd
Author: Vanessa <lly219@gmail.com> Date: Tue Oct 3 08:39:36 2023 +0800 🎨 https://github.com/siyuan-note/siyuan/issues/8766 commit11cc108893
Author: Daniel <845765@qq.com> Date: Tue Oct 3 07:57:36 2023 +0800 🐛 Create doc with ref Fix https://github.com/siyuan-note/siyuan/issues/9329 commitd869aef346
Author: Daniel <845765@qq.com> Date: Mon Oct 2 22:46:36 2023 +0800 🎨 The access authorization code command line parameter must be set when deploying via Docker https://github.com/siyuan-note/siyuan/issues/9328 commit3d7bf2eb0f
Author: Daniel <845765@qq.com> Date: Mon Oct 2 22:39:08 2023 +0800 🎨 Remove the access authorization code setting item on the browser-end https://github.com/siyuan-note/siyuan/issues/9331 commit279e17e8b5
Author: Daniel <845765@qq.com> Date: Mon Oct 2 22:15:33 2023 +0800 🎨 The access authorization code command line parameter must be set when deploying via Docker https://github.com/siyuan-note/siyuan/issues/9328 commitd2356754dd
Author: Daniel <845765@qq.com> Date: Sun Oct 1 18:41:51 2023 +0800 📝 Update changelogs commit4fdd0ddef0
Author: Daniel <845765@qq.com> Date: Sun Oct 1 18:37:39 2023 +0800 🎨 Add template type column to Attribute View https://github.com/siyuan-note/siyuan/issues/8766 commitb4bded40e3
Author: Daniel <845765@qq.com> Date: Sun Oct 1 18:24:16 2023 +0800 🎨 Add template type column to Attribute View https://github.com/siyuan-note/siyuan/issues/8766 commitbfd27a62d1
Author: Daniel <845765@qq.com> Date: Sun Oct 1 18:22:39 2023 +0800 🎨 Add template type column to Attribute View https://github.com/siyuan-note/siyuan/issues/8766 commit0aa61fe5b7
Author: Daniel <845765@qq.com> Date: Sun Oct 1 18:14:31 2023 +0800 🎨 Add template type column to Attribute View https://github.com/siyuan-note/siyuan/issues/8766 commit7d1e1bf2e5
Author: Daniel <845765@qq.com> Date: Sun Oct 1 18:02:31 2023 +0800 🎨 Add template type column to Attribute View https://github.com/siyuan-note/siyuan/issues/8766 commit8c31eb0eac
Author: Vanessa <lly219@gmail.com> Date: Sun Oct 1 17:59:16 2023 +0800 🎨 https://github.com/siyuan-note/siyuan/issues/8766 commit37892e786b
Author: Vanessa <lly219@gmail.com> Date: Sun Oct 1 17:58:48 2023 +0800 🎨 https://github.com/siyuan-note/siyuan/issues/8766 commitf965ef0945
Merge:b709c8458
b2f5ab570
Author: Vanessa <lly219@gmail.com> Date: Sun Oct 1 17:41:15 2023 +0800 Merge remote-tracking branch 'origin/dev' into dev commitb709c84585
Author: Vanessa <lly219@gmail.com> Date: Sun Oct 1 17:41:00 2023 +0800 🎨 https://github.com/siyuan-note/siyuan/issues/8766 commitb2f5ab5700
Author: Daniel <845765@qq.com> Date: Sun Oct 1 17:36:22 2023 +0800 🎨 Add template type column to Attribute View https://github.com/siyuan-note/siyuan/issues/8766 commitb833087cb6
Author: Daniel <845765@qq.com> Date: Sun Oct 1 17:33:53 2023 +0800 🎨 Add template type column to Attribute View https://github.com/siyuan-note/siyuan/issues/8766 commitdbdddd7ff3
Author: Daniel <845765@qq.com> Date: Sun Oct 1 17:16:08 2023 +0800 🎨 Add template type column to Attribute View https://github.com/siyuan-note/siyuan/issues/8766 commitb981fa08a0
Author: Vanessa <lly219@gmail.com> Date: Sun Oct 1 17:05:06 2023 +0800 🎨 https://github.com/siyuan-note/siyuan/issues/8766 commit6e475e1857
Author: Daniel <845765@qq.com> Date: Sun Oct 1 11:05:24 2023 +0800 📝 Update changelogs commitdf38f89f40
Merge:465375422
b69e8d335
Author: Vanessa <lly219@gmail.com> Date: Sun Oct 1 11:02:11 2023 +0800 Merge remote-tracking branch 'origin/dev' into dev commit4653754221
Author: Vanessa <lly219@gmail.com> Date: Sun Oct 1 11:01:57 2023 +0800 🎨 fix https://github.com/siyuan-note/siyuan/issues/9291 commitb69e8d3357
Author: Daniel <845765@qq.com> Date: Sun Oct 1 10:58:46 2023 +0800 🎨 Add template type column to Attribute View https://github.com/siyuan-note/siyuan/issues/8766 commitdf487a7c6a
Author: Vanessa <lly219@gmail.com> Date: Sun Oct 1 10:49:52 2023 +0800 🐛 flash card zoomin status commitc0424caf67
Author: Daniel <845765@qq.com> Date: Sun Oct 1 10:42:12 2023 +0800 🎨 Add template type column to Attribute View https://github.com/siyuan-note/siyuan/issues/8766 commite8359edebc
Author: Vanessa <lly219@gmail.com> Date: Sun Oct 1 10:27:07 2023 +0800 🚨 commitc3212235b7
Merge:64900706b
702926430
Author: Vanessa <lly219@gmail.com> Date: Sun Oct 1 10:26:51 2023 +0800 Merge remote-tracking branch 'origin/dev' into dev commit64900706b2
Author: Vanessa <lly219@gmail.com> Date: Sun Oct 1 10:26:31 2023 +0800 🎨 fix https://github.com/siyuan-note/siyuan/issues/9313 commit7029264300
Author: Daniel <845765@qq.com> Date: Sun Oct 1 10:03:07 2023 +0800 📝 Update changelogs commit29d155d0cd
Author: Daniel <845765@qq.com> Date: Sun Oct 1 09:37:46 2023 +0800 🎨 Improve missing line breaks when exporting RTF Fix https://github.com/siyuan-note/siyuan/issues/9325 commit05cfcf7c2b
Author: Vanessa <lly219@gmail.com> Date: Sat Sep 30 20:46:00 2023 +0800 🎨 https://ld246.com/article/1695361968294 commit67e0dad0a7
Merge:856445a6e
fee908d01
Author: Vanessa <lly219@gmail.com> Date: Sat Sep 30 20:30:21 2023 +0800 Merge remote-tracking branch 'origin/dev' into dev commit856445a6ef
Author: Vanessa <lly219@gmail.com> Date: Sat Sep 30 20:30:06 2023 +0800 🎨 fix https://github.com/siyuan-note/siyuan/issues/9323 commitfee908d01e
Author: Daniel <845765@qq.com> Date: Sat Sep 30 20:19:26 2023 +0800 🐛 The image does not display after pasting some PDF rectangular annotations Fix https://github.com/siyuan-note/siyuan/issues/9321 commit11d2f7c580
Author: Daniel <845765@qq.com> Date: Sat Sep 30 20:18:27 2023 +0800 🐛 The image does not display after pasting some PDF rectangular annotations Fix https://github.com/siyuan-note/siyuan/issues/9321 commit83dce4f3e6
Merge:1f2faecf4
49d92538d
Author: Vanessa <lly219@gmail.com> Date: Sat Sep 30 19:55:15 2023 +0800 Merge remote-tracking branch 'origin/dev' into dev commit1f2faecf4d
Author: Vanessa <lly219@gmail.com> Date: Sat Sep 30 19:55:01 2023 +0800 ⚡ breadcrumb commit49d92538df
Author: Daniel <845765@qq.com> Date: Sat Sep 30 19:52:26 2023 +0800 🐛 The subdoc creation path is unstable when a parent doc with the same name exists Fix https://github.com/siyuan-note/siyuan/issues/9322 commit17dd264479
Author: Daniel <845765@qq.com> Date: Sat Sep 30 19:34:28 2023 +0800 🎨 Improve handling of copy block ref when including images https://github.com/siyuan-note/siyuan/issues/9317 commite74733b4e1
Author: Daniel <845765@qq.com> Date: Sat Sep 30 17:57:23 2023 +0800 ♻️ Refactor create doc by hpath commitf608da26a5
Merge:6b2a4ff0a
121d33e74
Author: Vanessa <lly219@gmail.com> Date: Sat Sep 30 19:25:39 2023 +0800 Merge remote-tracking branch 'origin/dev' into dev commit6b2a4ff0aa
Author: Vanessa <lly219@gmail.com> Date: Sat Sep 30 19:25:20 2023 +0800 🎨 fix https://github.com/siyuan-note/siyuan/issues/9317 commit121d33e74d
Author: Daniel <845765@qq.com> Date: Sat Sep 30 17:56:47 2023 +0800 🎨 Improve handling of copy block ref when including images https://github.com/siyuan-note/siyuan/issues/9317 commit82bed847e6
Author: Vanessa <lly219@gmail.com> Date: Sat Sep 30 14:40:45 2023 +0800 🎨 https://github.com/siyuan-note/siyuan/issues/9320 commitf8b272d596
Merge:2dae1200b
ca855c1fa
Author: Vanessa <lly219@gmail.com> Date: Sat Sep 30 13:57:55 2023 +0800 Merge remote-tracking branch 'origin/dev' into dev commit2dae1200b4
Author: Vanessa <lly219@gmail.com> Date: Sat Sep 30 13:57:40 2023 +0800 🎨 https://github.com/siyuan-note/siyuan/issues/9316 commitca855c1fa5
Author: Daniel <845765@qq.com> Date: Sat Sep 30 11:57:37 2023 +0800 🎨 Attribute Panel - Database sort attributes by view column order https://github.com/siyuan-note/siyuan/issues/9319 commit1063f50375
Author: Vanessa <lly219@gmail.com> Date: Sat Sep 30 11:21:46 2023 +0800 💄 https://github.com/siyuan-note/siyuan/issues/9318 commit1f899aaf3c
Author: Vanessa <lly219@gmail.com> Date: Fri Sep 29 21:41:14 2023 +0800 💄 fix https://github.com/siyuan-note/siyuan/issues/9281 commit2b9bec8e8b
Author: Daniel <845765@qq.com> Date: Fri Sep 29 17:33:18 2023 +0800 🎨 Ctrl+N should follow notebook create save path https://ld246.com/article/1695965429553 commit41e35ea795
Author: Vanessa <lly219@gmail.com> Date: Thu Sep 28 23:45:23 2023 +0800 🚨 commit6a37b86613
Author: Vanessa <lly219@gmail.com> Date: Thu Sep 28 23:41:44 2023 +0800 🚨 commit4c6b695dae
Merge:df3f444e4
dc03a5cf3
Author: Vanessa <lly219@gmail.com> Date: Thu Sep 28 23:41:18 2023 +0800 Merge remote-tracking branch 'origin/dev' into dev commitdf3f444e48
Author: Vanessa <lly219@gmail.com> Date: Thu Sep 28 23:40:44 2023 +0800 ♻️ https://github.com/siyuan-note/siyuan/pull/9300 commitdc03a5cf38
Author: Daniel <845765@qq.com> Date: Thu Sep 28 22:46:29 2023 +0800 ⬆️ Upgrade kernel deps commit172b7ed018
Author: Daniel <845765@qq.com> Date: Thu Sep 28 22:39:12 2023 +0800 🎨 Apply result optimized by FSRS optimizer https://github.com/siyuan-note/siyuan/issues/9309 commit6354d04e4b
Author: Daniel <845765@qq.com> Date: Thu Sep 28 22:22:17 2023 +0800 🎨 Apply result optimized by FSRS optimizer https://github.com/siyuan-note/siyuan/issues/9309 commitb2a27bb54c
Author: Yingyi / 颖逸 <49649786+Zuoqiu-Yingyi@users.noreply.github.com> Date: Thu Sep 28 22:38:49 2023 +0800 Refactor code language and ts types (#9300) * 🎨 Code block language list adds custom languages * Update index.d.ts * 🎨 Improve global variable type definition * 🎨 Improve global variable type definition * 🎨 Add constant `EXTRA_CODE_LANGUAGES` commit17d2a16a94
Author: Vanessa <lly219@gmail.com> Date: Thu Sep 28 22:31:33 2023 +0800 🎨 fix https://github.com/siyuan-note/siyuan/issues/9264 commitceb9aef1d6
Author: Vanessa <lly219@gmail.com> Date: Thu Sep 28 17:25:18 2023 +0800 🎨 fix https://github.com/siyuan-note/siyuan/issues/9303 * 🎨 Improve the width of image in attribute view cell * 🎨 Adjust the style of rows' gutter * Merge tag 'v2.10.9-dev2' into feat/attrs-view-adaptive-width * 🎨 Improve the style of rows' gutter * 🐛 Improve the style of icon in attribute view * 🎨 Improve preview text fields * Revert Merge tag 'v2.10.9-dev2' into feat/attrs-view-adaptive-width * 🎨 Improve the style of image in attribute view cell * 🎨 Improve the style of firstcol * 🐛 Fix check icon click event handle * Merge tag 'v2.10.9-dev3' into feat/attrs-view-adaptive-width * Merge tag 'v2.10.9' into feat/attrs-view-adaptive-width * Merge tag 'v2.10.10' into feat/attrs-view-adaptive-width * Squashed commit of the following: commitc8924e37ae
Author: Vanessa <lly219@gmail.com> Date: Sat Oct 14 12:14:12 2023 +0800 🎨 fix https://github.com/siyuan-note/siyuan/issues/9409 commit879fdd827d
Author: Vanessa <lly219@gmail.com> Date: Sat Oct 14 11:56:16 2023 +0800 💄 dragover commit9978827389
Author: Vanessa <lly219@gmail.com> Date: Sat Oct 14 11:34:42 2023 +0800 🎨 数据库块适配外观和宽度调整 commita20ffeb12b
Author: Vanessa <lly219@gmail.com> Date: Sat Oct 14 11:20:17 2023 +0800 💄 fix https://github.com/siyuan-note/siyuan/issues/9412 commitf2075fafac
Author: Vanessa <lly219@gmail.com> Date: Sat Oct 14 11:04:23 2023 +0800 🎨 https://github.com/siyuan-note/siyuan/issues/9419 commit5e2910a4e6
Author: Vanessa <lly219@gmail.com> Date: Sat Oct 14 11:00:46 2023 +0800 🎨 https://github.com/siyuan-note/siyuan/issues/9419 commitac7f8d36df
Merge:9ae8400b4
d78a0205f
Author: Vanessa <lly219@gmail.com> Date: Sat Oct 14 10:56:40 2023 +0800 Merge remote-tracking branch 'origin/dev' into dev commit9ae8400b47
Author: Vanessa <lly219@gmail.com> Date: Sat Oct 14 10:56:21 2023 +0800 🎨 https://github.com/siyuan-note/siyuan/issues/9419 commitd78a0205f5
Author: Daniel <845765@qq.com> Date: Sat Oct 14 10:51:46 2023 +0800 🎨 Database table view breadcrumb commit6b1a2925c9
Merge:25109b906
9766020b8
Author: Vanessa <lly219@gmail.com> Date: Sat Oct 14 10:49:46 2023 +0800 Merge remote-tracking branch 'origin/dev' into dev commit25109b906f
Author: Vanessa <lly219@gmail.com> Date: Sat Oct 14 10:49:35 2023 +0800 🎨 数据库块适配外观和宽度调整 commit9766020b89
Author: Daniel <845765@qq.com> Date: Sat Oct 14 10:08:57 2023 +0800 🎨 Update text commitab67389650
Merge:7d6f9bb0d
39c5744f2
Author: Vanessa <lly219@gmail.com> Date: Sat Oct 14 10:01:57 2023 +0800 Merge remote-tracking branch 'origin/dev' into dev commit7d6f9bb0df
Author: Vanessa <lly219@gmail.com> Date: Sat Oct 14 10:01:42 2023 +0800 🎨 数据库不能设置布局 commit39c5744f2f
Author: Daniel <845765@qq.com> Date: Sat Oct 14 09:46:29 2023 +0800 🐛 Database table view export does not display select content Fix https://github.com/siyuan-note/siyuan/issues/9428 commit87ecb7f24a
Author: Daniel <845765@qq.com> Date: Sat Oct 14 09:37:47 2023 +0800 🎨 Update text commit69d8c93c98
Merge:623f30b5f
f6780c126
Author: Vanessa <lly219@gmail.com> Date: Sat Oct 14 09:21:54 2023 +0800 Merge remote-tracking branch 'origin/dev' into dev commit623f30b5fc
Author: Vanessa <lly219@gmail.com> Date: Sat Oct 14 09:21:44 2023 +0800 🎨 https://github.com/siyuan-note/siyuan/issues/9419 commitf6780c126a
Author: Daniel <845765@qq.com> Date: Sat Oct 14 09:20:51 2023 +0800 🎨 Supports searching database view content https://github.com/siyuan-note/siyuan/issues/9419 commitfd94e9df0c
Author: Vanessa <lly219@gmail.com> Date: Sat Oct 14 00:04:16 2023 +0800 🎨 commit51f66879cc
Author: Vanessa <lly219@gmail.com> Date: Fri Oct 13 23:50:31 2023 +0800 🎨 https://github.com/siyuan-note/siyuan/issues/9419 commit49305b8911
Merge:2f0f563e1
8399aba10
Author: Vanessa <lly219@gmail.com> Date: Fri Oct 13 23:26:15 2023 +0800 Merge remote-tracking branch 'origin/dev' into dev commit2f0f563e12
Author: Vanessa <lly219@gmail.com> Date: Fri Oct 13 23:25:58 2023 +0800 🎨 https://github.com/siyuan-note/siyuan/issues/9419 commit8399aba10b
Author: Daniel <845765@qq.com> Date: Fri Oct 13 23:22:17 2023 +0800 🎨 Supports searching database view content https://github.com/siyuan-note/siyuan/issues/9419 commit22efb3d523
Merge:f95084e96
c3d1c04af
Author: Vanessa <lly219@gmail.com> Date: Fri Oct 13 23:07:13 2023 +0800 Merge remote-tracking branch 'origin/dev' into dev commitf95084e96a
Author: Vanessa <lly219@gmail.com> Date: Fri Oct 13 23:06:53 2023 +0800 🎨 https://github.com/siyuan-note/siyuan/issues/9419 commitc3d1c04af4
Author: Daniel <845765@qq.com> Date: Fri Oct 13 22:50:11 2023 +0800 🎨 Supports searching database view content https://github.com/siyuan-note/siyuan/issues/9419 commita11ea9c347
Author: Vanessa <lly219@gmail.com> Date: Fri Oct 13 22:37:15 2023 +0800 💄 commit99ec5c10a4
Author: Vanessa <lly219@gmail.com> Date: Fri Oct 13 22:32:17 2023 +0800 🎨 showHiddenFiles commit49426ac916
Author: Vanessa <lly219@gmail.com> Date: Fri Oct 13 22:15:20 2023 +0800 🎨 https://github.com/siyuan-note/siyuan/issues/9425 commitd445c5401f
Author: Vanessa <lly219@gmail.com> Date: Fri Oct 13 21:54:35 2023 +0800 🎨 https://github.com/siyuan-note/siyuan/issues/9421 commit0c4aee7388
Merge:c34d84ce2
daa9ddfd5
Author: Vanessa <lly219@gmail.com> Date: Fri Oct 13 21:50:28 2023 +0800 Merge remote-tracking branch 'origin/dev' into dev commitc34d84ce29
Author: Vanessa <lly219@gmail.com> Date: Fri Oct 13 21:50:14 2023 +0800 🎨 https://github.com/siyuan-note/siyuan/issues/9421 commitdaa9ddfd50
Author: Daniel <845765@qq.com> Date: Fri Oct 13 14:43:43 2023 +0800 🎨 Don't load plugin when the user hasn't agreed to trust bazaar content yet Fix https://github.com/siyuan-note/siyuan/issues/9426 commit01b19ea2c8
Author: Daniel <845765@qq.com> Date: Fri Oct 13 14:03:41 2023 +0800 🎨 Fix database table view loading https://ld246.com/article/1697168944677 commit7a9a85ea32
Author: Vanessa <lly219@gmail.com> Date: Fri Oct 13 13:55:27 2023 +0800 🎨 https://github.com/siyuan-note/siyuan/issues/9417 commit1815ec1b39
Merge:73edee57a
00ed190ad
Author: Vanessa <lly219@gmail.com> Date: Fri Oct 13 13:37:45 2023 +0800 Merge remote-tracking branch 'origin/dev' into dev commit73edee57a4
Author: Vanessa <lly219@gmail.com> Date: Fri Oct 13 13:37:32 2023 +0800 🎨 https://github.com/siyuan-note/siyuan/issues/9417 commit00ed190ad7
Author: Daniel <845765@qq.com> Date: Fri Oct 13 13:21:53 2023 +0800 🎨 Fix database table view loading https://ld246.com/article/1697168944677 commit48e871c75e
Author: Vanessa <lly219@gmail.com> Date: Fri Oct 13 12:33:29 2023 +0800 🎨 https://github.com/siyuan-note/siyuan/issues/9417 commit3554333da9
Author: Vanessa <lly219@gmail.com> Date: Fri Oct 13 11:55:51 2023 +0800 🎨 https://github.com/siyuan-note/siyuan/issues/9417 commitaf810b279d
Author: Vanessa <lly219@gmail.com> Date: Fri Oct 13 11:34:19 2023 +0800 🎨 fix https://github.com/siyuan-note/siyuan/issues/9423 commit673c952f07
Author: Vanessa <lly219@gmail.com> Date: Fri Oct 13 11:30:44 2023 +0800 🎨 fix https://github.com/siyuan-note/siyuan/issues/9423 commit3b87a0d9ed
Merge:ed31305d1
3de7781b1
Author: Vanessa <lly219@gmail.com> Date: Fri Oct 13 11:09:07 2023 +0800 Merge remote-tracking branch 'origin/dev' into dev commited31305d1d
Author: Vanessa <lly219@gmail.com> Date: Fri Oct 13 11:08:56 2023 +0800 🎨 https://github.com/siyuan-note/siyuan/issues/9421 commit3de7781b1c
Author: Daniel <845765@qq.com> Date: Fri Oct 13 10:44:29 2023 +0800 🎨 Supports searching database view content https://github.com/siyuan-note/siyuan/issues/9419 commit2304921fee
Author: Daniel <845765@qq.com> Date: Fri Oct 13 10:42:51 2023 +0800 🎨 Update flashcard user guide commit55fb8b19ab
Author: Vanessa <lly219@gmail.com> Date: Fri Oct 13 10:14:11 2023 +0800 🎨 fix https://github.com/siyuan-note/siyuan/issues/9420 commit8998de9d81
Merge:5b38e79be
df9b55c71
Author: Vanessa <lly219@gmail.com> Date: Fri Oct 13 09:37:35 2023 +0800 Merge remote-tracking branch 'origin/dev' into dev commit5b38e79be7
Author: Vanessa <lly219@gmail.com> Date: Fri Oct 13 09:37:24 2023 +0800 🎨 fix https://github.com/siyuan-note/siyuan/issues/9420 commitdf9b55c71b
Author: Daniel <845765@qq.com> Date: Fri Oct 13 08:46:29 2023 +0800 🎨 Database template columns support sort commit3da9f0f1e1
Author: Vanessa <lly219@gmail.com> Date: Thu Oct 12 20:40:09 2023 +0800 🐛 新增行后弹出的输入框 commit79a88dfbec
Author: Vanessa <lly219@gmail.com> Date: Thu Oct 12 20:23:18 2023 +0800 🚨 commit40a1e6d5cc
Author: Vanessa <lly219@gmail.com> Date: Thu Oct 12 20:21:53 2023 +0800 💄 database loading commit2872dab9eb
Author: Vanessa <lly219@gmail.com> Date: Thu Oct 12 20:11:59 2023 +0800 💄 fix https://github.com/siyuan-note/siyuan/issues/9418 commit025a8ea5a7
Merge:02ec0f6e5
0ea9b8f5a
Author: Vanessa <lly219@gmail.com> Date: Thu Oct 12 20:04:13 2023 +0800 Merge remote-tracking branch 'origin/dev' into dev commit02ec0f6e5a
Author: Vanessa <lly219@gmail.com> Date: Thu Oct 12 20:04:01 2023 +0800 💄 fix https://github.com/siyuan-note/siyuan/issues/9418 commit0ea9b8f5a7
Author: Daniel <845765@qq.com> Date: Thu Oct 12 19:58:32 2023 +0800 🎨 Database block loading animation https://github.com/siyuan-note/siyuan/issues/9416 commit1590913db7
Author: Daniel <845765@qq.com> Date: Thu Oct 12 19:55:57 2023 +0800 🎨 Update attr panel for av commitd257caff8d
Author: Daniel <845765@qq.com> Date: Thu Oct 12 19:38:37 2023 +0800 🎨 Database block loading animation https://github.com/siyuan-note/siyuan/issues/9416 commitfdaf8d7e59
Merge:70e82cd98
238609f25
Author: Vanessa <lly219@gmail.com> Date: Thu Oct 12 17:34:36 2023 +0800 Merge remote-tracking branch 'origin/dev' into dev commit70e82cd981
Author: Vanessa <lly219@gmail.com> Date: Thu Oct 12 17:34:19 2023 +0800 💄 fix https://github.com/siyuan-note/siyuan/issues/9416 commit238609f25f
Author: Daniel <845765@qq.com> Date: Thu Oct 12 17:33:23 2023 +0800 ⚡ Improve performance of loading database table view commit2dd558b609
Merge:fe0b1e8d6
8fb35f556
Author: Vanessa <lly219@gmail.com> Date: Thu Oct 12 17:16:45 2023 +0800 Merge remote-tracking branch 'origin/dev' into dev commitfe0b1e8d60
Author: Vanessa <lly219@gmail.com> Date: Thu Oct 12 17:16:31 2023 +0800 💄 fix https://github.com/siyuan-note/siyuan/issues/9415 commit8fb35f5565
Author: Daniel <845765@qq.com> Date: Thu Oct 12 17:15:36 2023 +0800 🎨 Database template columns support number filter Fix https://github.com/siyuan-note/siyuan/issues/9414 commit01670f2b00
Merge:f792d141f
ffcdb5d39
Author: Vanessa <lly219@gmail.com> Date: Thu Oct 12 17:07:48 2023 +0800 Merge remote-tracking branch 'origin/dev' into dev commitf792d141fc
Author: Vanessa <lly219@gmail.com> Date: Thu Oct 12 17:07:09 2023 +0800 🎨 https://github.com/siyuan-note/siyuan/issues/9408 commitffcdb5d398
Author: Daniel <845765@qq.com> Date: Thu Oct 12 16:37:09 2023 +0800 🐛 SVG images cannot be displayed on some systems https://github.com/siyuan-note/siyuan/issues/9413 commitfb1f80cf4d
Author: Vanessa <lly219@gmail.com> Date: Thu Oct 12 12:22:55 2023 +0800 💄 fix https://github.com/siyuan-note/siyuan/issues/9406 commitda51aded35
Merge:a4bcae87e
09ef5fddf
Author: Vanessa <lly219@gmail.com> Date: Thu Oct 12 12:11:42 2023 +0800 Merge remote-tracking branch 'origin/dev' into dev commita4bcae87ee
Author: Vanessa <lly219@gmail.com> Date: Thu Oct 12 12:11:29 2023 +0800 🐛 数据库数字填0无效 commit09ef5fddf9
Author: Daniel <845765@qq.com> Date: Thu Oct 12 12:01:53 2023 +0800 🎨 Database template columns support calculations https://github.com/siyuan-note/siyuan/issues/9408 commit1b595d014a
Author: Vanessa <lly219@gmail.com> Date: Thu Oct 12 12:01:53 2023 +0800 🎨 #9408 commit21d1a0515a
Author: Vanessa <lly219@gmail.com> Date: Thu Oct 12 11:54:15 2023 +0800 💄 编辑后表头不固定 commitc5206f7084
Author: Vanessa <lly219@gmail.com> Date: Thu Oct 12 11:14:29 2023 +0800 🐛 fix https://github.com/siyuan-note/siyuan/issues/9405 commitf0f55d3b02
Merge:019412404
92151f715
Author: Vanessa <lly219@gmail.com> Date: Thu Oct 12 10:54:19 2023 +0800 Merge remote-tracking branch 'origin/dev' into dev commit0194124047
Author: Vanessa <lly219@gmail.com> Date: Thu Oct 12 10:54:09 2023 +0800 💄 fix https://github.com/siyuan-note/siyuan/issues/9403 commit92151f7150
Author: Daniel <845765@qq.com> Date: Thu Oct 12 10:12:44 2023 +0800 🎨 Change database template column custom attribute action Fix https://github.com/siyuan-note/siyuan/issues/9401 commitb8e8aa0593
Author: Daniel <845765@qq.com> Date: Wed Oct 11 17:00:21 2023 +0800 🔨 Clean code commitb17aff5773
Author: Vanessa <lly219@gmail.com> Date: Wed Oct 11 23:54:40 2023 +0800 🐛 commit11174958bc
Author: Vanessa <lly219@gmail.com> Date: Wed Oct 11 23:50:28 2023 +0800 🐛 预览模式下点击只读 commit130884d758
Author: Vanessa <lly219@gmail.com> Date: Wed Oct 11 23:23:01 2023 +0800 🎨 fix https://github.com/siyuan-note/siyuan/issues/9404 commit7486e1a6e2
Author: Vanessa <lly219@gmail.com> Date: Wed Oct 11 17:28:40 2023 +0800 🎨 fix https://github.com/siyuan-note/siyuan/issues/9402 commiteb93255cf3
Author: Daniel <845765@qq.com> Date: Wed Oct 11 14:57:14 2023 +0800 🔨 Clean code commitfd46593815
Author: Daniel <845765@qq.com> Date: Wed Oct 11 14:55:06 2023 +0800 🔖 Release v2.10.10 commit337c79571d
Author: Daniel <845765@qq.com> Date: Wed Oct 11 11:59:25 2023 +0800 🎨 Improve install new version on Windows commitf6f1148de1
Author: Daniel <845765@qq.com> Date: Wed Oct 11 11:08:44 2023 +0800 📝 Update changelogs commitf0ad3268ba
Author: Vanessa <lly219@gmail.com> Date: Wed Oct 11 11:30:00 2023 +0800 🎨 commit2eb89f0673
Author: Vanessa <lly219@gmail.com> Date: Wed Oct 11 11:25:21 2023 +0800 🚨 commit0db516e4b9
Merge:23c3f9f15
e43cf4cf5
Author: Vanessa <lly219@gmail.com> Date: Wed Oct 11 11:24:41 2023 +0800 Merge remote-tracking branch 'origin/dev' into dev commit23c3f9f154
Author: Vanessa <lly219@gmail.com> Date: Wed Oct 11 11:24:29 2023 +0800 🎨 fix https://github.com/siyuan-note/siyuan/issues/9383 commite43cf4cf55
Author: Daniel <845765@qq.com> Date: Wed Oct 11 10:52:10 2023 +0800 📝 Update changelogs commitb30cb0984a
Author: Daniel <845765@qq.com> Date: Wed Oct 11 10:49:04 2023 +0800 📝 Update changelogs commitd4a3226a56
Author: Daniel <845765@qq.com> Date: Wed Oct 11 10:48:40 2023 +0800 📝 Update changelogs commit65adab61c9
Author: Daniel <845765@qq.com> Date: Wed Oct 11 10:48:29 2023 +0800 🎨 Adding row overwriting data after enabling filter in database https://github.com/siyuan-note/siyuan/issues/9395 commit210a3ac547
Author: Daniel <845765@qq.com> Date: Wed Oct 11 10:04:39 2023 +0800 🎨 Improve handling of database column filters containing empty values Fix https://github.com/siyuan-note/siyuan/issues/9394 commit37f950ba4f
Author: Vanessa <lly219@gmail.com> Date: Wed Oct 11 09:39:22 2023 +0800 💄 icon commit7b1c30bc26
Author: Vanessa <lly219@gmail.com> Date: Wed Oct 11 09:30:13 2023 +0800 🎨 fix https://github.com/siyuan-note/siyuan/issues/9396 commit6ef13aba78
Merge:acd2eb167
e4907e789
Author: Vanessa <lly219@gmail.com> Date: Wed Oct 11 09:18:43 2023 +0800 Merge remote-tracking branch 'origin/dev' into dev commitacd2eb1677
Author: Vanessa <lly219@gmail.com> Date: Wed Oct 11 09:18:33 2023 +0800 🎨 fix https://github.com/siyuan-note/siyuan/issues/9396 commite4907e7896
Author: Daniel <845765@qq.com> Date: Wed Oct 11 09:16:57 2023 +0800 🎨 The block in the editor shows the database icon https://github.com/siyuan-note/siyuan/issues/8894 commit6f249d768f
Author: Daniel <845765@qq.com> Date: Wed Oct 11 09:15:03 2023 +0800 ⬆️ Upgrade kernel deps commitbb04bf9f70
Author: Daniel <845765@qq.com> Date: Wed Oct 11 09:04:39 2023 +0800 🎨 Show notebooks in hpath of block ref search list results https://github.com/siyuan-note/siyuan/issues/9378 commit30b0dd08fa
Merge:c1de5e148
ccb65454a
Author: Vanessa <lly219@gmail.com> Date: Wed Oct 11 08:58:55 2023 +0800 Merge remote-tracking branch 'origin/dev' into dev commitc1de5e1488
Author: Vanessa <lly219@gmail.com> Date: Wed Oct 11 08:58:44 2023 +0800 💄 https://github.com/siyuan-note/siyuan/issues/8894 commitccb65454a2
Author: Daniel <845765@qq.com> Date: Wed Oct 11 08:50:13 2023 +0800 🎨 Improve handling of database column filters containing empty values Fix https://github.com/siyuan-note/siyuan/issues/9394 commit28e4e1ef2f
Author: Daniel <845765@qq.com> Date: Tue Oct 10 22:31:46 2023 +0800 🎨 Rename the .sya annotation file when renaming a PDF asset https://github.com/siyuan-note/siyuan/issues/9390 commit964c822c2b
Author: Daniel <845765@qq.com> Date: Tue Oct 10 22:02:46 2023 +0800 🎨 Improve database created and updated column values https://github.com/siyuan-note/siyuan/issues/9391 commitf404d7fe85
Merge:ed7084c7b
301b6d9f7
Author: Vanessa <lly219@gmail.com> Date: Tue Oct 10 22:00:57 2023 +0800 Merge remote-tracking branch 'origin/dev' into dev commited7084c7be
Author: Vanessa <lly219@gmail.com> Date: Tue Oct 10 22:00:43 2023 +0800 💄 commit301b6d9f70
Author: Daniel <845765@qq.com> Date: Tue Oct 10 21:55:43 2023 +0800 🎨 Improve database created and updated column values https://github.com/siyuan-note/siyuan/issues/9391 commitf62be4719e
Author: Vanessa <lly219@gmail.com> Date: Tue Oct 10 21:50:36 2023 +0800 🎨 fix https://github.com/siyuan-note/siyuan/issues/9385 commit8e2565f347
Author: Vanessa <lly219@gmail.com> Date: Tue Oct 10 21:39:57 2023 +0800 🎨 fix https://github.com/siyuan-note/siyuan/issues/9386 commite54d8f1a4d
Author: Vanessa <lly219@gmail.com> Date: Tue Oct 10 21:31:20 2023 +0800 🎨 fix https://github.com/siyuan-note/siyuan/issues/9393 commit1fb7187936
Author: Vanessa <lly219@gmail.com> Date: Tue Oct 10 21:23:29 2023 +0800 📝 fix https://github.com/siyuan-note/siyuan/issues/9392 commitea00753f38
Author: Vanessa <lly219@gmail.com> Date: Tue Oct 10 21:18:17 2023 +0800 🎨 fix https://github.com/siyuan-note/siyuan/issues/9392 commit4318aa4463
Author: Vanessa <lly219@gmail.com> Date: Tue Oct 10 20:51:28 2023 +0800 🎨 fix https://github.com/siyuan-note/siyuan/issues/9376 commitf1d4f8472b
Merge:3f4c00efc
64df2ffa4
Author: Vanessa <lly219@gmail.com> Date: Tue Oct 10 20:42:43 2023 +0800 Merge remote-tracking branch 'origin/dev' into dev commit3f4c00efcd
Author: Vanessa <lly219@gmail.com> Date: Tue Oct 10 20:42:14 2023 +0800 🎨 https://github.com/siyuan-note/siyuan/issues/9376 commit64df2ffa42
Author: Daniel <845765@qq.com> Date: Tue Oct 10 20:37:51 2023 +0800 🎨 Rows in the database without bound blocks should not show created and updated Fix https://github.com/siyuan-note/siyuan/issues/9391 commit691a0bea33
Merge:0e5cae300
7e9243d8d
Author: Vanessa <lly219@gmail.com> Date: Tue Oct 10 20:41:05 2023 +0800 Merge remote-tracking branch 'origin/dev' into dev commit0e5cae3001
Author: Vanessa <lly219@gmail.com> Date: Tue Oct 10 20:40:38 2023 +0800 💄 fix https://github.com/siyuan-note/siyuan/issues/9206 commit7e9243d8dc
Author: Daniel <845765@qq.com> Date: Tue Oct 10 20:05:48 2023 +0800 🎨 Rows in the database without bound blocks should not show created and updated Fix https://github.com/siyuan-note/siyuan/issues/9391 commit7aa4aacfc3
Author: Vanessa <lly219@gmail.com> Date: Tue Oct 10 17:30:10 2023 +0800 💄 fix https://github.com/siyuan-note/siyuan/issues/9206 commitd02381d3f2
Merge:449d2dbf8
6e9099ea1
Author: Vanessa <lly219@gmail.com> Date: Tue Oct 10 17:09:14 2023 +0800 Merge remote-tracking branch 'origin/dev' into dev commit449d2dbf87
Author: Vanessa <lly219@gmail.com> Date: Tue Oct 10 17:09:03 2023 +0800 ♻️ https://github.com/siyuan-note/siyuan/pull/9256 commit6e9099ea12
Author: Daniel <845765@qq.com> Date: Tue Oct 10 16:52:40 2023 +0800 🔒 Authenticate requests of assets other than 127.0.0.1 Fix https://github.com/siyuan-note/siyuan/issues/9388 commit11786381cf
Author: Yingyi / 颖逸 <49649786+Zuoqiu-Yingyi@users.noreply.github.com> Date: Tue Oct 10 16:21:50 2023 +0800 Improve event bus `open-siyuan-url-plugin` (#9256) * 🎨 Improve plugin event bus `open-siyuan-url-plugin` * 🐛 Avoid plug-in names with the same prefix * Update onGetConfig.ts commit2c36af78bc
Author: Vanessa <lly219@gmail.com> Date: Tue Oct 10 16:15:24 2023 +0800 🚨 commitb0e3efa774
Author: Daniel <845765@qq.com> Date: Tue Oct 10 11:41:46 2023 +0800 🔖 Release v2.10.9 commitd690475ae6
Merge:c8a6f4185
811bac942
Author: Daniel <845765@qq.com> Date: Tue Oct 10 10:58:46 2023 +0800 Merge remote-tracking branch 'origin/master' commitc8a6f4185e
Author: Daniel <845765@qq.com> Date: Tue Oct 10 10:18:57 2023 +0800 🔖 Release v2.10.9 commitcdcec7e58d
Author: Daniel <845765@qq.com> Date: Mon Oct 9 23:29:25 2023 +0800 📝 Update changelogs commit1eccb8ba4d
Merge:a3094fe3e
3827753b7
Author: Vanessa <lly219@gmail.com> Date: Mon Oct 9 23:26:13 2023 +0800 Merge remote-tracking branch 'origin/dev' into dev commita3094fe3ea
Author: Vanessa <lly219@gmail.com> Date: Mon Oct 9 23:25:48 2023 +0800 🐛 fix https://github.com/siyuan-note/siyuan/issues/9384 commit3827753b7c
Author: Daniel <845765@qq.com> Date: Mon Oct 9 23:07:34 2023 +0800 🎨 Upgrade Electron https://github.com/siyuan-note/siyuan/issues/9342 commit567394afba
Author: Daniel <845765@qq.com> Date: Mon Oct 9 22:42:39 2023 +0800 📝 Update changelogs commitff6220abaa
Author: Yingyi / 颖逸 <49649786+Zuoqiu-Yingyi@users.noreply.github.com> Date: Mon Oct 9 21:51:39 2023 +0800 🎨 add `@electron/remote` dependency (#9381) commitda0fa0853f
Author: Daniel <845765@qq.com> Date: Mon Oct 9 21:45:36 2023 +0800 🎨 Replace non-breaking spaces with normal spaces when copying https://github.com/siyuan-note/siyuan/issues/9382 commit0ed6884761
Author: Daniel <845765@qq.com> Date: Mon Oct 9 21:09:35 2023 +0800 🐛 Update av Fix https://github.com/siyuan-note/siyuan/issues/9380 commit288eb24474
Author: Daniel <845765@qq.com> Date: Mon Oct 9 17:30:19 2023 +0800 🎨 Show notebooks in hpath of block ref search list results https://github.com/siyuan-note/siyuan/issues/9378 commit4965b7b845
Merge:803069d80
902849153
Author: Vanessa <lly219@gmail.com> Date: Mon Oct 9 17:18:28 2023 +0800 Merge remote-tracking branch 'origin/dev' into dev commit803069d807
Author: Vanessa <lly219@gmail.com> Date: Mon Oct 9 17:18:17 2023 +0800 🎨 fix https://github.com/siyuan-note/siyuan/issues/9370 commit902849153a
Author: Daniel <845765@qq.com> Date: Mon Oct 9 17:17:40 2023 +0800 🎨 Add created and updated type column to database https://github.com/siyuan-note/siyuan/issues/9371 commitfaadbf5960
Author: Daniel <845765@qq.com> Date: Mon Oct 9 16:48:28 2023 +0800 🎨 Add created and updated type column to database https://github.com/siyuan-note/siyuan/issues/9371 commit9ca11625bd
Merge:43f06e57d
644e0319d
Author: Vanessa <lly219@gmail.com> Date: Mon Oct 9 16:45:06 2023 +0800 Merge remote-tracking branch 'origin/dev' into dev commit43f06e57d9
Author: Vanessa <lly219@gmail.com> Date: Mon Oct 9 16:44:46 2023 +0800 🎨 fix https://github.com/siyuan-note/siyuan/issues/9370 commit811bac942d
Author: Daniel <845765@qq.com> Date: Wed Oct 4 13:03:36 2023 +0800 🎨 Free disk space for docker image building GitHub Action commit66aa802765
Author: Daniel <845765@qq.com> Date: Wed Oct 4 13:03:28 2023 +0800 🎨 Free disk space for docker image building GitHub Action * Update anno.ts * Update index.ts * 🎨 Adapt to align styles * 🎨 Adapt to using arrow keys/Esc to select a cell/row * Update row.ts * 🎨 Adjusted the cell width in attribute view * 🐛 Fixed the issue that the first column was misaligned * Update index.ts * Update action.ts
This commit is contained in:
parent
695029776c
commit
2e46bee776
@ -1,4 +1,8 @@
|
|||||||
.av {
|
.av {
|
||||||
|
display: flex;
|
||||||
|
flex-direction: column;
|
||||||
|
align-items: center;
|
||||||
|
|
||||||
user-select: none;
|
user-select: none;
|
||||||
box-sizing: border-box;
|
box-sizing: border-box;
|
||||||
|
|
||||||
@ -27,6 +31,11 @@
|
|||||||
opacity: 1;
|
opacity: 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
&__container {
|
||||||
|
// width: fit-content;
|
||||||
|
max-width: 100%;
|
||||||
|
}
|
||||||
|
|
||||||
&__header {
|
&__header {
|
||||||
top: -43px;
|
top: -43px;
|
||||||
z-index: 2;
|
z-index: 2;
|
||||||
@ -60,14 +69,15 @@
|
|||||||
|
|
||||||
&__gutters {
|
&__gutters {
|
||||||
@extend .protyle-gutters;
|
@extend .protyle-gutters;
|
||||||
position: fixed;
|
position: absolute;
|
||||||
|
line-height: normal;
|
||||||
top: 0;
|
top: 0;
|
||||||
left: -44px;
|
left: 0;
|
||||||
opacity: 0;
|
opacity: 0;
|
||||||
display: flex;
|
width: 24px;
|
||||||
|
|
||||||
svg {
|
button {
|
||||||
height: 25px;
|
padding: 0;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -84,6 +94,10 @@
|
|||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
&__body {
|
||||||
|
float: left;
|
||||||
|
}
|
||||||
|
|
||||||
&__row {
|
&__row {
|
||||||
display: flex;
|
display: flex;
|
||||||
border-bottom: 1px solid var(--b3-theme-surface-lighter);
|
border-bottom: 1px solid var(--b3-theme-surface-lighter);
|
||||||
@ -111,10 +125,6 @@
|
|||||||
|
|
||||||
&--select {
|
&--select {
|
||||||
background-color: var(--b3-theme-primary-lightest);
|
background-color: var(--b3-theme-primary-lightest);
|
||||||
|
|
||||||
.av__firstcol svg {
|
|
||||||
opacity: 1;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
&--header {
|
&--header {
|
||||||
@ -181,18 +191,15 @@
|
|||||||
|
|
||||||
&--add {
|
&--add {
|
||||||
color: var(--b3-theme-on-surface);
|
color: var(--b3-theme-on-surface);
|
||||||
padding: 5px 5px 5px 7px;
|
|
||||||
display: flex;
|
display: flex;
|
||||||
align-items: center;
|
|
||||||
transition: background 20ms ease-in 0s;
|
transition: background 20ms ease-in 0s;
|
||||||
font-size: 87.5%;
|
font-size: 87.5%;
|
||||||
|
|
||||||
svg {
|
.av__calc {
|
||||||
height: 12px;
|
padding: 0 5px;
|
||||||
width: 12px;
|
align-items: center;
|
||||||
color: var(--b3-theme-on-surface);
|
position: sticky;
|
||||||
margin-right: 5px;
|
left: 49px;
|
||||||
flex-shrink: 0;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
&:hover {
|
&:hover {
|
||||||
@ -201,6 +208,27 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
&__firstcol {
|
||||||
|
display: flex;
|
||||||
|
flex-direction: row-reverse;
|
||||||
|
|
||||||
|
position: sticky;
|
||||||
|
left: 0;
|
||||||
|
z-index: 1;
|
||||||
|
width: 48px;
|
||||||
|
background-color: var(--b3-theme-background);
|
||||||
|
border-right: 1px solid var(--b3-theme-surface-lighter);
|
||||||
|
|
||||||
|
svg {
|
||||||
|
color: var(--b3-theme-on-surface);
|
||||||
|
height: 36px;
|
||||||
|
width: 24px;
|
||||||
|
padding: 5px;
|
||||||
|
box-sizing: border-box;
|
||||||
|
float: left;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
&__cell {
|
&__cell {
|
||||||
box-sizing: border-box;
|
box-sizing: border-box;
|
||||||
position: relative;
|
position: relative;
|
||||||
@ -234,6 +262,18 @@
|
|||||||
top: 5px;
|
top: 5px;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
&[data-wrap=true] {
|
||||||
|
white-space: pre-wrap;
|
||||||
|
}
|
||||||
|
|
||||||
|
&[data-wrap=false] {
|
||||||
|
white-space: nowrap;
|
||||||
|
|
||||||
|
img.av__cellassetimg {
|
||||||
|
max-height: 26px;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
&:hover .block__icon {
|
&:hover .block__icon {
|
||||||
opacity: 1;
|
opacity: 1;
|
||||||
background-color: var(--b3-theme-background-light) !important;
|
background-color: var(--b3-theme-background-light) !important;
|
||||||
@ -259,6 +299,7 @@
|
|||||||
|
|
||||||
&__celltext {
|
&__celltext {
|
||||||
overflow: hidden;
|
overflow: hidden;
|
||||||
|
line-height: normal;
|
||||||
|
|
||||||
.b3-chip {
|
.b3-chip {
|
||||||
margin: 1px 2px;
|
margin: 1px 2px;
|
||||||
@ -276,22 +317,6 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
&__firstcol {
|
|
||||||
svg {
|
|
||||||
color: var(--b3-theme-on-surface);
|
|
||||||
height: 33px;
|
|
||||||
width: 24px;
|
|
||||||
opacity: 0;
|
|
||||||
padding: 5px;
|
|
||||||
box-sizing: border-box;
|
|
||||||
float: left;
|
|
||||||
}
|
|
||||||
|
|
||||||
&:hover svg {
|
|
||||||
opacity: 1;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
&__widthdrag {
|
&__widthdrag {
|
||||||
position: absolute;
|
position: absolute;
|
||||||
cursor: col-resize;
|
cursor: col-resize;
|
||||||
@ -373,20 +398,13 @@
|
|||||||
&.protyle-wysiwyg--select,
|
&.protyle-wysiwyg--select,
|
||||||
&.protyle-wysiwyg--hl {
|
&.protyle-wysiwyg--hl {
|
||||||
.av__row--header,
|
.av__row--header,
|
||||||
.av__row--footer {
|
.av__row--footer,
|
||||||
|
.av__firstcol {
|
||||||
background-color: transparent;
|
background-color: transparent;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
img.av__cellassetimg {
|
|
||||||
max-height: 20px;
|
|
||||||
border-radius: var(--b3-border-radius);
|
|
||||||
margin: 1px 2px;
|
|
||||||
max-width: none;
|
|
||||||
vertical-align: top;
|
|
||||||
}
|
|
||||||
|
|
||||||
html[data-theme-mode="dark"] .av__panel .b3-menu__item {
|
html[data-theme-mode="dark"] .av__panel .b3-menu__item {
|
||||||
mix-blend-mode: lighten;
|
mix-blend-mode: lighten;
|
||||||
}
|
}
|
||||||
|
@ -69,6 +69,10 @@
|
|||||||
line-height: 26px;
|
line-height: 26px;
|
||||||
min-height: 26px;
|
min-height: 26px;
|
||||||
|
|
||||||
|
img.av__cellassetimg {
|
||||||
|
height: 32px;
|
||||||
|
}
|
||||||
|
|
||||||
&:hover {
|
&:hover {
|
||||||
background-color: var(--b3-theme-background);
|
background-color: var(--b3-theme-background);
|
||||||
}
|
}
|
||||||
|
@ -8,6 +8,7 @@
|
|||||||
-webkit-font-smoothing: subpixel-antialiased;
|
-webkit-font-smoothing: subpixel-antialiased;
|
||||||
color: var(--b3-tooltips-color);
|
color: var(--b3-tooltips-color);
|
||||||
word-wrap: break-word;
|
word-wrap: break-word;
|
||||||
|
white-space: pre;
|
||||||
background-color: var(--b3-tooltips-background);
|
background-color: var(--b3-tooltips-background);
|
||||||
border-radius: var(--b3-border-radius);
|
border-radius: var(--b3-border-radius);
|
||||||
line-height: 17px;
|
line-height: 17px;
|
||||||
|
@ -4,18 +4,10 @@ import {Plugin} from "./index";
|
|||||||
/// #if !MOBILE
|
/// #if !MOBILE
|
||||||
import {exportLayout, resizeTopBar} from "../layout/util";
|
import {exportLayout, resizeTopBar} from "../layout/util";
|
||||||
/// #endif
|
/// #endif
|
||||||
import {API} from "./API";
|
import {PluginRequire} from "./require";
|
||||||
import {getFrontend, isMobile, isWindow} from "../util/functions";
|
import {getFrontend, isMobile, isWindow} from "../util/functions";
|
||||||
import {Constants} from "../constants";
|
import {Constants} from "../constants";
|
||||||
|
|
||||||
const getObject = (key: string) => {
|
|
||||||
const api = {
|
|
||||||
siyuan: API
|
|
||||||
};
|
|
||||||
// @ts-ignore
|
|
||||||
return api[key];
|
|
||||||
};
|
|
||||||
|
|
||||||
const runCode = (code: string, sourceURL: string) => {
|
const runCode = (code: string, sourceURL: string) => {
|
||||||
return window.eval("(function anonymous(require, module, exports){".concat(code, "\n})\n//# sourceURL=").concat(sourceURL, "\n"));
|
return window.eval("(function anonymous(require, module, exports){".concat(code, "\n})\n//# sourceURL=").concat(sourceURL, "\n"));
|
||||||
};
|
};
|
||||||
@ -40,7 +32,7 @@ const loadPluginJS = async (app: App, item: IPluginData) => {
|
|||||||
const exportsObj: { [key: string]: any } = {};
|
const exportsObj: { [key: string]: any } = {};
|
||||||
const moduleObj = {exports: exportsObj};
|
const moduleObj = {exports: exportsObj};
|
||||||
try {
|
try {
|
||||||
runCode(item.js, "plugin:" + encodeURIComponent(item.name))(getObject, moduleObj, exportsObj);
|
runCode(item.js, "plugin:" + encodeURIComponent(item.name))(PluginRequire.require, moduleObj, exportsObj);
|
||||||
} catch (e) {
|
} catch (e) {
|
||||||
console.error(`plugin ${item.name} run error:`, e);
|
console.error(`plugin ${item.name} run error:`, e);
|
||||||
return;
|
return;
|
||||||
|
11
app/src/plugin/require.ts
Normal file
11
app/src/plugin/require.ts
Normal file
@ -0,0 +1,11 @@
|
|||||||
|
import {API as siyuan} from "./API";
|
||||||
|
|
||||||
|
const libs: Record<string, any> = {
|
||||||
|
siyuan,
|
||||||
|
} as const;
|
||||||
|
|
||||||
|
export const PluginRequire = {
|
||||||
|
require(module: string) {
|
||||||
|
return libs[module];
|
||||||
|
}
|
||||||
|
}
|
@ -1616,8 +1616,7 @@ export class Gutter {
|
|||||||
click: () => {
|
click: () => {
|
||||||
this.genClick(nodeElements, protyle, (e: HTMLElement) => {
|
this.genClick(nodeElements, protyle, (e: HTMLElement) => {
|
||||||
if (e.classList.contains("av")) {
|
if (e.classList.contains("av")) {
|
||||||
e.style.margin = "";
|
e.style.alignItems = "flex-start";
|
||||||
resizeAV(e);
|
|
||||||
} else {
|
} else {
|
||||||
e.style.textAlign = "left";
|
e.style.textAlign = "left";
|
||||||
}
|
}
|
||||||
@ -1630,8 +1629,7 @@ export class Gutter {
|
|||||||
click: () => {
|
click: () => {
|
||||||
this.genClick(nodeElements, protyle, (e: HTMLElement) => {
|
this.genClick(nodeElements, protyle, (e: HTMLElement) => {
|
||||||
if (e.classList.contains("av")) {
|
if (e.classList.contains("av")) {
|
||||||
e.style.margin = "0 auto";
|
e.style.alignItems = "center";
|
||||||
resizeAV(e);
|
|
||||||
} else {
|
} else {
|
||||||
e.style.textAlign = "center";
|
e.style.textAlign = "center";
|
||||||
}
|
}
|
||||||
@ -1644,8 +1642,7 @@ export class Gutter {
|
|||||||
click: () => {
|
click: () => {
|
||||||
this.genClick(nodeElements, protyle, (e: HTMLElement) => {
|
this.genClick(nodeElements, protyle, (e: HTMLElement) => {
|
||||||
if (e.classList.contains("av")) {
|
if (e.classList.contains("av")) {
|
||||||
e.style.margin = "0 0 0 auto";
|
e.style.alignItems = "flex-end";
|
||||||
resizeAV(e);
|
|
||||||
} else {
|
} else {
|
||||||
e.style.textAlign = "right";
|
e.style.textAlign = "right";
|
||||||
}
|
}
|
||||||
@ -1656,7 +1653,11 @@ export class Gutter {
|
|||||||
icon: "iconMenu",
|
icon: "iconMenu",
|
||||||
click: () => {
|
click: () => {
|
||||||
this.genClick(nodeElements, protyle, (e: HTMLElement) => {
|
this.genClick(nodeElements, protyle, (e: HTMLElement) => {
|
||||||
|
if (e.classList.contains("av")) {
|
||||||
|
e.style.alignItems = "stretch";
|
||||||
|
} else {
|
||||||
e.style.textAlign = "justify";
|
e.style.textAlign = "justify";
|
||||||
|
}
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
}, {
|
}, {
|
||||||
@ -1686,12 +1687,11 @@ export class Gutter {
|
|||||||
icon: "iconTrashcan",
|
icon: "iconTrashcan",
|
||||||
click: () => {
|
click: () => {
|
||||||
this.genClick(nodeElements, protyle, (e: HTMLElement) => {
|
this.genClick(nodeElements, protyle, (e: HTMLElement) => {
|
||||||
|
e.style.direction = "";
|
||||||
if (e.classList.contains("av")) {
|
if (e.classList.contains("av")) {
|
||||||
e.style.margin = "";
|
e.style.alignItems = "";
|
||||||
resizeAV(e);
|
|
||||||
} else {
|
} else {
|
||||||
e.style.textAlign = "";
|
e.style.textAlign = "";
|
||||||
e.style.direction = "";
|
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
@ -1754,7 +1754,6 @@ export class Gutter {
|
|||||||
id: e.getAttribute("data-node-id"),
|
id: e.getAttribute("data-node-id"),
|
||||||
data: e.outerHTML
|
data: e.outerHTML
|
||||||
});
|
});
|
||||||
resizeAV(e);
|
|
||||||
});
|
});
|
||||||
transaction(protyle, operations, undoOperations);
|
transaction(protyle, operations, undoOperations);
|
||||||
window.siyuan.menus.menu.remove();
|
window.siyuan.menus.menu.remove();
|
||||||
|
@ -24,6 +24,25 @@ import {unicode2Emoji} from "../../../emoji";
|
|||||||
import {selectRow} from "./row";
|
import {selectRow} from "./row";
|
||||||
import * as dayjs from "dayjs";
|
import * as dayjs from "dayjs";
|
||||||
|
|
||||||
|
export const avAdd = (protyle: IProtyle, blockElement: HTMLElement, rowElement: HTMLElement, above: boolean) => {
|
||||||
|
const avID = blockElement.getAttribute("data-av-id");
|
||||||
|
const srcIDs = [Lute.NewNodeID()];
|
||||||
|
const previousID = above ? (rowElement.previousElementSibling.getAttribute("data-id") || "") : rowElement.getAttribute("data-id");
|
||||||
|
transaction(protyle, [{
|
||||||
|
action: "insertAttrViewBlock",
|
||||||
|
avID,
|
||||||
|
previousID,
|
||||||
|
srcIDs,
|
||||||
|
isDetached: true,
|
||||||
|
}], [{
|
||||||
|
action: "removeAttrViewBlock",
|
||||||
|
srcIDs,
|
||||||
|
avID,
|
||||||
|
}]);
|
||||||
|
insertAttrViewBlockAnimation(blockElement, 1, previousID, avID);
|
||||||
|
popTextCell(protyle, [rowElement[above ? "previousElementSibling" : "nextElementSibling"].querySelector('[data-detached="true"]')], "block");
|
||||||
|
}
|
||||||
|
|
||||||
export const avClick = (protyle: IProtyle, event: MouseEvent & { target: HTMLElement }) => {
|
export const avClick = (protyle: IProtyle, event: MouseEvent & { target: HTMLElement }) => {
|
||||||
const blockElement = hasClosestBlock(event.target);
|
const blockElement = hasClosestBlock(event.target);
|
||||||
if (!blockElement) {
|
if (!blockElement) {
|
||||||
@ -37,6 +56,29 @@ export const avClick = (protyle: IProtyle, event: MouseEvent & { target: HTMLEle
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
const addRowElement = hasClosestByClassName(event.target, "av__row--add");
|
||||||
|
if (addRowElement) {
|
||||||
|
const avID = blockElement.getAttribute("data-av-id");
|
||||||
|
const srcIDs = [Lute.NewNodeID()];
|
||||||
|
const previousID = addRowElement.previousElementSibling.getAttribute("data-id") || "";
|
||||||
|
transaction(protyle, [{
|
||||||
|
action: "insertAttrViewBlock",
|
||||||
|
avID,
|
||||||
|
previousID,
|
||||||
|
srcIDs,
|
||||||
|
isDetached: true,
|
||||||
|
}], [{
|
||||||
|
action: "removeAttrViewBlock",
|
||||||
|
srcIDs,
|
||||||
|
avID,
|
||||||
|
}]);
|
||||||
|
insertAttrViewBlockAnimation(blockElement, 1, previousID, avID);
|
||||||
|
popTextCell(protyle, [addRowElement.previousElementSibling.querySelector('[data-detached="true"]')], "block");
|
||||||
|
event.preventDefault();
|
||||||
|
event.stopPropagation();
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
const copyElement = hasClosestByAttribute(event.target, "data-type", "copy");
|
const copyElement = hasClosestByAttribute(event.target, "data-type", "copy");
|
||||||
if (copyElement) {
|
if (copyElement) {
|
||||||
writeText(copyElement.previousElementSibling.textContent.trim());
|
writeText(copyElement.previousElementSibling.textContent.trim());
|
||||||
@ -63,26 +105,11 @@ export const avClick = (protyle: IProtyle, event: MouseEvent & { target: HTMLEle
|
|||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
const gutterElement = hasClosestByClassName(event.target, "ariaLabel");
|
const gutterElement = hasClosestByClassName(event.target, "av__gutter");
|
||||||
if (gutterElement && gutterElement.parentElement.classList.contains("av__gutters")) {
|
if (gutterElement && gutterElement.parentElement.classList.contains("av__gutters")) {
|
||||||
const rowElement = gutterElement.parentElement.parentElement;
|
const rowElement = gutterElement.parentElement.parentElement.parentElement;
|
||||||
if (gutterElement.dataset.action === "add") {
|
if (gutterElement.dataset.action === "add") {
|
||||||
const avID = blockElement.getAttribute("data-av-id");
|
avAdd(protyle, blockElement, rowElement, event.altKey);
|
||||||
const srcIDs = [Lute.NewNodeID()];
|
|
||||||
const previousID = event.altKey ? (rowElement.previousElementSibling.getAttribute("data-id") || "") : rowElement.getAttribute("data-id");
|
|
||||||
transaction(protyle, [{
|
|
||||||
action: "insertAttrViewBlock",
|
|
||||||
avID,
|
|
||||||
previousID,
|
|
||||||
srcIDs,
|
|
||||||
isDetached: true,
|
|
||||||
}], [{
|
|
||||||
action: "removeAttrViewBlock",
|
|
||||||
srcIDs,
|
|
||||||
avID,
|
|
||||||
}]);
|
|
||||||
insertAttrViewBlockAnimation(blockElement, 1, previousID, avID);
|
|
||||||
popTextCell(protyle, [rowElement[event.altKey ? "previousElementSibling" : "nextElementSibling"].querySelector('[data-detached="true"]')], "block");
|
|
||||||
} else {
|
} else {
|
||||||
const gutterRect = gutterElement.getBoundingClientRect();
|
const gutterRect = gutterElement.getBoundingClientRect();
|
||||||
avContextmenu(protyle, rowElement, {
|
avContextmenu(protyle, rowElement, {
|
||||||
@ -97,10 +124,10 @@ export const avClick = (protyle: IProtyle, event: MouseEvent & { target: HTMLEle
|
|||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
const checkElement = hasClosestByClassName(event.target, "av__firstcol");
|
const firstcolElement = hasClosestByClassName(event.target, "av__firstcol");
|
||||||
if (checkElement) {
|
if (firstcolElement) {
|
||||||
window.siyuan.menus.menu.remove();
|
window.siyuan.menus.menu.remove();
|
||||||
selectRow(checkElement, "toggle");
|
selectRow(firstcolElement, "toggle");
|
||||||
event.preventDefault();
|
event.preventDefault();
|
||||||
event.stopPropagation();
|
event.stopPropagation();
|
||||||
return true;
|
return true;
|
||||||
@ -202,7 +229,7 @@ export const avClick = (protyle: IProtyle, event: MouseEvent & { target: HTMLEle
|
|||||||
selectRow(cellElement.parentElement.querySelector(".av__firstcol"), "toggle");
|
selectRow(cellElement.parentElement.querySelector(".av__firstcol"), "toggle");
|
||||||
} else {
|
} else {
|
||||||
cellElement.parentElement.parentElement.querySelectorAll(".av__row--select").forEach(item => {
|
cellElement.parentElement.parentElement.querySelectorAll(".av__row--select").forEach(item => {
|
||||||
item.querySelector(".av__firstcol use").setAttribute("xlink:href", "#iconUncheck");
|
item.querySelector(".av__firstcol .icon__check use").setAttribute("xlink:href", "#iconUncheck");
|
||||||
item.classList.remove("av__row--select");
|
item.classList.remove("av__row--select");
|
||||||
});
|
});
|
||||||
updateHeader(cellElement.parentElement);
|
updateHeader(cellElement.parentElement);
|
||||||
@ -221,29 +248,6 @@ export const avClick = (protyle: IProtyle, event: MouseEvent & { target: HTMLEle
|
|||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
const addRowElement = hasClosestByClassName(event.target, "av__row--add");
|
|
||||||
if (addRowElement) {
|
|
||||||
const avID = blockElement.getAttribute("data-av-id");
|
|
||||||
const srcIDs = [Lute.NewNodeID()];
|
|
||||||
const previousID = addRowElement.previousElementSibling.getAttribute("data-id") || "";
|
|
||||||
transaction(protyle, [{
|
|
||||||
action: "insertAttrViewBlock",
|
|
||||||
avID,
|
|
||||||
previousID,
|
|
||||||
srcIDs,
|
|
||||||
isDetached: true,
|
|
||||||
}], [{
|
|
||||||
action: "removeAttrViewBlock",
|
|
||||||
srcIDs,
|
|
||||||
avID,
|
|
||||||
}]);
|
|
||||||
insertAttrViewBlockAnimation(blockElement, 1, previousID, avID);
|
|
||||||
popTextCell(protyle, [addRowElement.previousElementSibling.querySelector('[data-detached="true"]')], "block");
|
|
||||||
event.preventDefault();
|
|
||||||
event.stopPropagation();
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
return false;
|
return false;
|
||||||
};
|
};
|
||||||
|
|
||||||
@ -259,7 +263,7 @@ export const avContextmenu = (protyle: IProtyle, rowElement: HTMLElement, positi
|
|||||||
blockElement.querySelectorAll(".av__row--select").forEach(item => {
|
blockElement.querySelectorAll(".av__row--select").forEach(item => {
|
||||||
item.classList.remove("av__row--select");
|
item.classList.remove("av__row--select");
|
||||||
});
|
});
|
||||||
blockElement.querySelectorAll(".av__firstcol use").forEach(item => {
|
blockElement.querySelectorAll(".av__firstcol .icon__check use").forEach(item => {
|
||||||
item.setAttribute("xlink:href", "#iconUncheck");
|
item.setAttribute("xlink:href", "#iconUncheck");
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
@ -269,7 +273,7 @@ export const avContextmenu = (protyle: IProtyle, rowElement: HTMLElement, positi
|
|||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
rowElement.classList.add("av__row--select");
|
rowElement.classList.add("av__row--select");
|
||||||
rowElement.querySelector(".av__firstcol use").setAttribute("xlink:href", "#iconCheck");
|
rowElement.querySelector(".av__firstcol .icon__check use").setAttribute("xlink:href", "#iconCheck");
|
||||||
const rowIds: string[] = [];
|
const rowIds: string[] = [];
|
||||||
const blockIds: string[] = [];
|
const blockIds: string[] = [];
|
||||||
const rowElements = blockElement.querySelectorAll(".av__row--select:not(.av__row--header)");
|
const rowElements = blockElement.querySelectorAll(".av__row--select:not(.av__row--header)");
|
||||||
@ -305,6 +309,24 @@ export const avContextmenu = (protyle: IProtyle, rowElement: HTMLElement, positi
|
|||||||
}
|
}
|
||||||
});
|
});
|
||||||
if (rowIds.length === 1) {
|
if (rowIds.length === 1) {
|
||||||
|
menu.addSeparator();
|
||||||
|
menu.addItem({
|
||||||
|
label: window.siyuan.languages.addAttr,
|
||||||
|
icon: "iconAdd",
|
||||||
|
type: "submenu",
|
||||||
|
submenu: [
|
||||||
|
{
|
||||||
|
label: window.siyuan.languages.insertRowAbove,
|
||||||
|
icon: "iconBefore",
|
||||||
|
click: () => avAdd(protyle, blockElement, rowElement, true),
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: window.siyuan.languages.insertRowBelow,
|
||||||
|
icon: "iconAfter",
|
||||||
|
click: () => avAdd(protyle, blockElement, rowElement, false),
|
||||||
|
},
|
||||||
|
]
|
||||||
|
});
|
||||||
menu.addSeparator();
|
menu.addSeparator();
|
||||||
openEditorTab(protyle.app, rowIds[0]);
|
openEditorTab(protyle.app, rowIds[0]);
|
||||||
menu.addItem({
|
menu.addItem({
|
||||||
|
@ -53,13 +53,13 @@ export const avRender = (element: Element, protyle: IProtyle, cb?: () => void) =
|
|||||||
}, (response) => {
|
}, (response) => {
|
||||||
const data = response.data.view as IAVTable;
|
const data = response.data.view as IAVTable;
|
||||||
// header
|
// header
|
||||||
let tableHTML = '<div class="av__row av__row--header"><div class="av__firstcol"><svg style="height: 32px"><use xlink:href="#iconUncheck"></use></svg></div>';
|
let tableHTML = '<div class="av__row av__row--header"><div class="av__firstcol"><svg class="icon__check"><use xlink:href="#iconUncheck"></use></svg></div>';
|
||||||
let calcHTML = "";
|
let calcHTML = "";
|
||||||
data.columns.forEach((column: IAVColumn) => {
|
data.columns.forEach((column: IAVColumn) => {
|
||||||
if (column.hidden) {
|
if (column.hidden) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
tableHTML += `<div class="av__cell" data-col-id="${column.id}" data-icon="${column.icon}" data-dtype="${column.type}"
|
tableHTML += `<div class="av__cell" data-col-id="${column.id}" data-icon="${column.icon}" data-dtype="${column.type}" data-wrap="${column.wrap}"
|
||||||
style="width: ${column.width || "200px"};
|
style="width: ${column.width || "200px"};
|
||||||
${column.wrap ? "" : "white-space: nowrap;"}">
|
${column.wrap ? "" : "white-space: nowrap;"}">
|
||||||
<div draggable="true" class="av__cellheader">
|
<div draggable="true" class="av__cellheader">
|
||||||
@ -80,11 +80,17 @@ style="width: ${column.width || "200px"}">${getCalcValue(column) || '<svg><use x
|
|||||||
// body
|
// body
|
||||||
data.rows.forEach((row: IAVRow) => {
|
data.rows.forEach((row: IAVRow) => {
|
||||||
tableHTML += `<div class="av__row" data-id="${row.id}">
|
tableHTML += `<div class="av__row" data-id="${row.id}">
|
||||||
<div class="av__gutters">
|
<div class="av__firstcol">
|
||||||
<button class="ariaLabel" data-action="add" data-position="right" aria-label="${isMac() ? window.siyuan.languages.addBelowAbove : window.siyuan.languages.addBelowAbove.replace("⌥", "Alt+")}"><svg><use xlink:href="#iconAdd"></use></svg></button>
|
<svg class="icon__check"><use xlink:href="#iconUncheck"></use></svg>
|
||||||
<button class="ariaLabel" draggable="true" data-position="right" aria-label="${window.siyuan.languages.rowTip}"><svg><use xlink:href="#iconDrag"></use></svg></button>
|
<div class="av__gutters">
|
||||||
</div>
|
<button class="av__gutter ariaLabel" draggable="true" data-position="right" aria-label="${window.siyuan.languages.rowTip}">
|
||||||
<div class="av__firstcol"><svg><use xlink:href="#iconUncheck"></use></svg></div>`;
|
<svg><use xlink:href="#iconDrag"></use></svg>
|
||||||
|
</button>
|
||||||
|
<button class="av__gutter ariaLabel" data-action="add" data-position="right" aria-label="${isMac() ? window.siyuan.languages.addBelowAbove : window.siyuan.languages.addBelowAbove.replace("⌥", "Alt+")}">
|
||||||
|
<svg><use xlink:href="#iconAdd"></use></svg>
|
||||||
|
</button>
|
||||||
|
</div>
|
||||||
|
</div>`;
|
||||||
row.cells.forEach((cell, index) => {
|
row.cells.forEach((cell, index) => {
|
||||||
if (data.columns[index].hidden) {
|
if (data.columns[index].hidden) {
|
||||||
return;
|
return;
|
||||||
@ -154,12 +160,12 @@ style="width: ${column.width || "200px"}">${getCalcValue(column) || '<svg><use x
|
|||||||
text += `<span ${cell.valueType !== "number" ? "" : 'style="right:auto;left:5px"'} data-type="copy" class="b3-tooltips b3-tooltips__n block__icon" aria-label="${window.siyuan.languages.copy}"><svg><use xlink:href="#iconCopy"></use></svg></span>`;
|
text += `<span ${cell.valueType !== "number" ? "" : 'style="right:auto;left:5px"'} data-type="copy" class="b3-tooltips b3-tooltips__n block__icon" aria-label="${window.siyuan.languages.copy}"><svg><use xlink:href="#iconCopy"></use></svg></span>`;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
tableHTML += `<div class="av__cell" data-id="${cell.id}" data-col-id="${data.columns[index].id}"
|
|
||||||
|
tableHTML += `<div class="av__cell" data-id="${cell.id}" data-col-id="${data.columns[index].id}" data-wrap="${data.columns[index].wrap}"
|
||||||
${cell.valueType === "block" ? 'data-block-id="' + (cell.value.block.id || "") + '"' : ""}
|
${cell.valueType === "block" ? 'data-block-id="' + (cell.value.block.id || "") + '"' : ""}
|
||||||
${cell.value?.isDetached ? ' data-detached="true"' : ""}
|
${cell.value?.isDetached ? ' data-detached="true"' : ""}
|
||||||
style="width: ${data.columns[index].width || "200px"};
|
style="width: ${data.columns[index].width || "200px"};
|
||||||
${cell.bgColor ? `background-color:${cell.bgColor};` : ""}
|
${cell.bgColor ? `background-color:${cell.bgColor};` : ""}
|
||||||
white-space: ${data.columns[index].wrap ? "pre-wrap" : "nowrap"};
|
|
||||||
${cell.valueType !== "number" ? "" : "flex-direction: row-reverse;"}
|
${cell.valueType !== "number" ? "" : "flex-direction: row-reverse;"}
|
||||||
${cell.color ? `color:${cell.color};` : ""}">${text}</div>`;
|
${cell.color ? `color:${cell.color};` : ""}">${text}</div>`;
|
||||||
});
|
});
|
||||||
@ -173,7 +179,7 @@ ${cell.color ? `color:${cell.color};` : ""}">${text}</div>`;
|
|||||||
</div>`;
|
</div>`;
|
||||||
});
|
});
|
||||||
setTimeout(() => {
|
setTimeout(() => {
|
||||||
e.firstElementChild.outerHTML = `<div>
|
e.firstElementChild.outerHTML = `<div class="av__container">
|
||||||
<div class="av__header">
|
<div class="av__header">
|
||||||
<div class="layout-tab-bar fn__flex">
|
<div class="layout-tab-bar fn__flex">
|
||||||
${tabHTML}
|
${tabHTML}
|
||||||
@ -197,13 +203,17 @@ ${cell.color ? `color:${cell.color};` : ""}">${text}</div>`;
|
|||||||
<div class="av__counter fn__none"></div>
|
<div class="av__counter fn__none"></div>
|
||||||
</div>
|
</div>
|
||||||
<div class="av__scroll">
|
<div class="av__scroll">
|
||||||
<div style="float: left;">
|
<div class="av__body">
|
||||||
${tableHTML}
|
${tableHTML}
|
||||||
<div class="av__row--add">
|
<div class="av__row--add">
|
||||||
|
<div class="av__firstcol">
|
||||||
<svg><use xlink:href="#iconAdd"></use></svg>
|
<svg><use xlink:href="#iconAdd"></use></svg>
|
||||||
|
</div>
|
||||||
|
<div class="av__calc" style>
|
||||||
${window.siyuan.languages.addAttr}
|
${window.siyuan.languages.addAttr}
|
||||||
</div>
|
</div>
|
||||||
<div class="av__row--footer"><div style="width: 24px"></div>${calcHTML}</div>
|
</div>
|
||||||
|
<div class="av__row--footer"><div class="av__firstcol"></div>${calcHTML}</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>`;
|
</div>`;
|
||||||
|
@ -1,27 +1,27 @@
|
|||||||
import {hasClosestBlock} from "../../util/hasClosest";
|
import {hasClosestBlock} from "../../util/hasClosest";
|
||||||
import {focusBlock} from "../../util/selection";
|
import {focusBlock} from "../../util/selection";
|
||||||
|
|
||||||
export const selectRow = (checkElement: Element, type: "toggle" | "select" | "unselect" | "unselectAll") => {
|
export const selectRow = (firstcolElement: Element, type: "toggle" | "select" | "unselect" | "unselectAll") => {
|
||||||
const rowElement = checkElement.parentElement;
|
const rowElement = firstcolElement.parentElement;
|
||||||
const useElement = checkElement.querySelector("use");
|
const useElement = firstcolElement.querySelector(".icon__check use");
|
||||||
if (rowElement.classList.contains("av__row--header") || type === "unselectAll") {
|
if (rowElement.classList.contains("av__row--header") || type === "unselectAll") {
|
||||||
if ("#iconCheck" === useElement.getAttribute("xlink:href")) {
|
if ("#iconCheck" === useElement.getAttribute("xlink:href")) {
|
||||||
rowElement.parentElement.querySelectorAll(".av__firstcol").forEach(item => {
|
rowElement.parentElement.querySelectorAll(".av__row .av__firstcol").forEach(item => {
|
||||||
item.querySelector("use").setAttribute("xlink:href", "#iconUncheck");
|
item.querySelector(".icon__check use").setAttribute("xlink:href", "#iconUncheck");
|
||||||
item.parentElement.classList.remove("av__row--select");
|
item.parentElement.classList.remove("av__row--select");
|
||||||
});
|
});
|
||||||
} else {
|
} else {
|
||||||
rowElement.parentElement.querySelectorAll(".av__firstcol").forEach(item => {
|
rowElement.parentElement.querySelectorAll(".av__row .av__firstcol").forEach(item => {
|
||||||
item.querySelector("use").setAttribute("xlink:href", "#iconCheck");
|
item.querySelector(".icon__check use").setAttribute("xlink:href", "#iconCheck");
|
||||||
item.parentElement.classList.add("av__row--select");
|
item.parentElement.classList.add("av__row--select");
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
if (type === "select" || (useElement.getAttribute("xlink:href") === "#iconUncheck" && type === "toggle")) {
|
if (type === "select" || (useElement.getAttribute("xlink:href") === "#iconUncheck" && type === "toggle")) {
|
||||||
checkElement.parentElement.classList.add("av__row--select");
|
firstcolElement.parentElement.classList.add("av__row--select");
|
||||||
useElement.setAttribute("xlink:href", "#iconCheck");
|
useElement.setAttribute("xlink:href", "#iconCheck");
|
||||||
} else if (type === "unselect" || (useElement.getAttribute("xlink:href") === "#iconCheck" && type === "toggle")) {
|
} else if (type === "unselect" || (useElement.getAttribute("xlink:href") === "#iconCheck" && type === "toggle")) {
|
||||||
checkElement.parentElement.classList.remove("av__row--select");
|
firstcolElement.parentElement.classList.remove("av__row--select");
|
||||||
useElement.setAttribute("xlink:href", "#iconUncheck");
|
useElement.setAttribute("xlink:href", "#iconUncheck");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -37,7 +37,7 @@ export const updateHeader = (rowElement: HTMLElement) => {
|
|||||||
const selectCount = rowElement.parentElement.querySelectorAll(".av__row--select:not(.av__row--header)").length;
|
const selectCount = rowElement.parentElement.querySelectorAll(".av__row--select:not(.av__row--header)").length;
|
||||||
const diffCount = rowElement.parentElement.childElementCount - 3 - selectCount;
|
const diffCount = rowElement.parentElement.childElementCount - 3 - selectCount;
|
||||||
const headElement = rowElement.parentElement.firstElementChild;
|
const headElement = rowElement.parentElement.firstElementChild;
|
||||||
const headUseElement = headElement.querySelector("use");
|
const headUseElement = headElement.querySelector(".icon__check use");
|
||||||
const counterElement = blockElement.querySelector(".av__counter");
|
const counterElement = blockElement.querySelector(".av__counter");
|
||||||
const avHeadElement = blockElement.querySelector(".av__header") as HTMLElement;
|
const avHeadElement = blockElement.querySelector(".av__header") as HTMLElement;
|
||||||
if (diffCount === 0 && rowElement.parentElement.childElementCount - 3 !== 0) {
|
if (diffCount === 0 && rowElement.parentElement.childElementCount - 3 !== 0) {
|
||||||
|
@ -24,30 +24,6 @@ export const scrollEvent = (protyle: IProtyle, element: HTMLElement) => {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
protyle.wysiwyg.element.querySelectorAll(".av").forEach((item: HTMLElement) => {
|
|
||||||
if (item.parentElement.classList.contains("protyle-wysiwyg")) {
|
|
||||||
const headerTop = item.offsetTop + 43;
|
|
||||||
const headerElement = item.querySelector(".av__row--header") as HTMLElement;
|
|
||||||
if (headerElement) {
|
|
||||||
if (headerTop < element.scrollTop && headerTop + headerElement.parentElement.clientHeight > element.scrollTop) {
|
|
||||||
headerElement.style.transform = `translateY(${element.scrollTop - headerTop}px)`;
|
|
||||||
} else {
|
|
||||||
headerElement.style.transform = "";
|
|
||||||
}
|
|
||||||
}
|
|
||||||
const footerElement = item.querySelector(".av__row--footer") as HTMLElement;
|
|
||||||
if (footerElement) {
|
|
||||||
const footerBottom = headerTop + footerElement.parentElement.clientHeight;
|
|
||||||
const scrollBottom = element.scrollTop + element.clientHeight + 5;
|
|
||||||
if (headerTop + 42 + 36 * 2 < scrollBottom && footerBottom > scrollBottom) {
|
|
||||||
footerElement.style.transform = `translateY(${scrollBottom - footerBottom}px)`;
|
|
||||||
} else {
|
|
||||||
footerElement.style.transform = "";
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
});
|
|
||||||
|
|
||||||
if (!protyle.element.classList.contains("block__edit") && !isMobile()) {
|
if (!protyle.element.classList.contains("block__edit") && !isMobile()) {
|
||||||
protyle.contentElement.setAttribute("data-scrolltop", element.scrollTop.toString());
|
protyle.contentElement.setAttribute("data-scrolltop", element.scrollTop.toString());
|
||||||
}
|
}
|
||||||
|
@ -42,11 +42,6 @@ export const resize = (protyle: IProtyle) => {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (abs.padding > MIN_ABS || abs.width > MIN_ABS || isNaN(abs.padding)) {
|
|
||||||
protyle.wysiwyg.element.querySelectorAll(".av").forEach((item: HTMLElement) => {
|
|
||||||
resizeAV(item);
|
|
||||||
});
|
|
||||||
}
|
|
||||||
}, Constants.TIMEOUT_TRANSITION); // 等待 setPadding 动画结束
|
}, Constants.TIMEOUT_TRANSITION); // 等待 setPadding 动画结束
|
||||||
};
|
};
|
||||||
|
|
||||||
@ -54,34 +49,11 @@ export const resizeAV = (item: HTMLElement) => {
|
|||||||
if (!item.classList.contains("av") || item.getAttribute("data-render") !== "true") {
|
if (!item.classList.contains("av") || item.getAttribute("data-render") !== "true") {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
const attrElement = item.querySelector(".protyle-attr") as HTMLElement
|
|
||||||
if (item.style.width.endsWith("%") || item.style.margin) {
|
const containerElement = item.querySelector<HTMLElement>(".av__container");
|
||||||
const avHeaderElement = item.firstElementChild.firstElementChild as HTMLElement;
|
if (item.style.width.endsWith("%")) {
|
||||||
avHeaderElement.style.paddingLeft = "";
|
containerElement.style.width = "auto";
|
||||||
avHeaderElement.style.paddingRight = "";
|
|
||||||
const avBodyElement = item.querySelector(".av__scroll").firstElementChild as HTMLElement;
|
|
||||||
avBodyElement.style.paddingLeft = "";
|
|
||||||
avBodyElement.style.paddingRight = "";
|
|
||||||
attrElement.style.paddingRight = "";
|
|
||||||
item.style.alignSelf = "";
|
|
||||||
if (!item.style.width.endsWith("%")) {
|
|
||||||
item.style.width = "";
|
|
||||||
item.style.maxWidth = "100%";
|
|
||||||
}
|
|
||||||
} else {
|
} else {
|
||||||
const paddingLeft = item.parentElement.style.paddingLeft;
|
containerElement.style.width = "";
|
||||||
const paddingRight = item.parentElement.style.paddingRight;
|
|
||||||
const avHeaderElement = item.firstElementChild.firstElementChild as HTMLElement;
|
|
||||||
avHeaderElement.style.paddingLeft = paddingLeft;
|
|
||||||
avHeaderElement.style.paddingRight = paddingRight;
|
|
||||||
const avBodyElement = item.querySelector(".av__scroll").firstElementChild as HTMLElement;
|
|
||||||
avBodyElement.style.paddingLeft = paddingLeft;
|
|
||||||
avBodyElement.style.paddingRight = paddingRight;
|
|
||||||
attrElement.style.paddingRight = paddingRight;
|
|
||||||
item.style.alignSelf = "center";
|
|
||||||
if (item.parentElement.clientWidth > 0) {
|
|
||||||
item.style.width = item.parentElement.clientWidth + "px";
|
|
||||||
item.style.maxWidth = "";
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
@ -1452,12 +1452,6 @@ export class WYSIWYG {
|
|||||||
if (embedElement) {
|
if (embedElement) {
|
||||||
protyle.gutter.render(protyle, embedElement, this.element);
|
protyle.gutter.render(protyle, embedElement, this.element);
|
||||||
} else {
|
} else {
|
||||||
// database 行块标
|
|
||||||
const rowElement = hasClosestByClassName(event.target, "av__row");
|
|
||||||
if (rowElement && rowElement.dataset.id) {
|
|
||||||
const rowRect = rowElement.getBoundingClientRect();
|
|
||||||
rowElement.firstElementChild.setAttribute("style", `left:${rowRect.left - 44}px;top:${rowRect.top}px`);
|
|
||||||
}
|
|
||||||
protyle.gutter.render(protyle, nodeElement, this.element);
|
protyle.gutter.render(protyle, nodeElement, this.element);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -69,7 +69,6 @@ import {escapeHtml} from "../../util/escape";
|
|||||||
import {insertHTML} from "../util/insertHTML";
|
import {insertHTML} from "../util/insertHTML";
|
||||||
import {removeSearchMark} from "../toolbar/util";
|
import {removeSearchMark} from "../toolbar/util";
|
||||||
import {avKeydown} from "../render/av/keydown";
|
import {avKeydown} from "../render/av/keydown";
|
||||||
import {resizeAV} from "../util/resize";
|
|
||||||
|
|
||||||
|
|
||||||
export const getContentByInlineHTML = (range: Range, cb: (content: string) => void) => {
|
export const getContentByInlineHTML = (range: Range, cb: (content: string) => void) => {
|
||||||
@ -1147,8 +1146,7 @@ export const keydown = (protyle: IProtyle, editorElement: HTMLElement) => {
|
|||||||
}
|
}
|
||||||
updateBatchTransaction(selectElements, protyle, (e: HTMLElement) => {
|
updateBatchTransaction(selectElements, protyle, (e: HTMLElement) => {
|
||||||
if (e.classList.contains("av")) {
|
if (e.classList.contains("av")) {
|
||||||
e.style.margin = "";
|
e.style.alignItems = "flex-start";
|
||||||
resizeAV(e);
|
|
||||||
} else {
|
} else {
|
||||||
e.style.textAlign = "left";
|
e.style.textAlign = "left";
|
||||||
}
|
}
|
||||||
@ -1169,8 +1167,7 @@ export const keydown = (protyle: IProtyle, editorElement: HTMLElement) => {
|
|||||||
}
|
}
|
||||||
updateBatchTransaction(selectElements, protyle, (e: HTMLElement) => {
|
updateBatchTransaction(selectElements, protyle, (e: HTMLElement) => {
|
||||||
if (e.classList.contains("av")) {
|
if (e.classList.contains("av")) {
|
||||||
e.style.margin = "0 auto";
|
e.style.alignItems = "center";
|
||||||
resizeAV(e);
|
|
||||||
} else {
|
} else {
|
||||||
e.style.textAlign = "center";
|
e.style.textAlign = "center";
|
||||||
}
|
}
|
||||||
@ -1187,8 +1184,7 @@ export const keydown = (protyle: IProtyle, editorElement: HTMLElement) => {
|
|||||||
}
|
}
|
||||||
updateBatchTransaction(selectElements, protyle, (e: HTMLElement) => {
|
updateBatchTransaction(selectElements, protyle, (e: HTMLElement) => {
|
||||||
if (e.classList.contains("av")) {
|
if (e.classList.contains("av")) {
|
||||||
e.style.margin = "0 0 0 auto";
|
e.style.alignItems = "flex-end";
|
||||||
resizeAV(e);
|
|
||||||
} else {
|
} else {
|
||||||
e.style.textAlign = "right";
|
e.style.textAlign = "right";
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user