Commit Graph

227 Commits

Author SHA1 Message Date
Tienson Qin
ebc801241d chore: remove repeated get-title-and-pagename calls 2024-01-30 15:58:10 +08:00
rcmerci
b020be6047 feat: import favorites from config-edn 2024-01-30 15:51:06 +08:00
Gabriel Horner
8f736e82c7 fix lint 2024-01-29 08:50:42 -05:00
rcmerci
2573e66d0a refactor: use :block/link to store favorite-page-db-id 2024-01-26 21:17:47 +08:00
rcmerci
c93c8b8c3e refactor: reorder favorites 2024-01-26 16:56:19 +08:00
rcmerci
3365482d34 feat: move favorites to db from config.edn in db-verison 2024-01-25 19:40:28 +08:00
Tienson Qin
6192378c28 fix: page merge
Page rename should be called from worker.
2024-01-16 17:51:54 +08:00
Tienson Qin
a619850998 Merge branch 'feat/db' into refactor/pipeline-worker 2024-01-16 15:42:18 +08:00
Gabriel Horner
2646a4cfbc enhance: add more deprecated file config keys and migrate on import 2024-01-10 15:26:19 -05:00
Tienson Qin
264f7dd40a Merge branch 'feat/db' into refactor/pipeline-worker 2024-01-11 02:57:37 +08:00
Tienson Qin
f7eafb00ce fix: property issues 2024-01-11 02:04:07 +08:00
Gabriel Horner
3f3cf8b17f enhance: migrate imported config to be valid
Also improves import ux as Invalid config notification no longer blocks
import progress
2024-01-10 12:19:42 -05:00
Tienson Qin
baefeaad5b fix: use page-handler/<create! if possible 2024-01-11 00:54:19 +08:00
Tienson Qin
7600a53929 Clean setTimeout 2024-01-10 23:52:47 +08:00
Tienson Qin
a503d451da fix: unit tests 2024-01-10 15:42:16 +08:00
Tienson Qin
4da564cd0b fix: open first block after creating a new page 2024-01-09 16:09:43 +08:00
Tienson Qin
77726bda4c fix: worker dependencies 2024-01-08 12:59:08 +08:00
Tienson Qin
8f8acf1d77 wip page rename 2024-01-07 16:27:11 +08:00
Tienson Qin
7c4baf97db fix both page create and delete 2024-01-05 03:09:35 +08:00
Tienson Qin
1e72d0efc7 Move page-delete to worker 2024-01-05 02:47:40 +08:00
Tienson Qin
086a052ee7 Move page-create to worker 2024-01-05 01:02:22 +08:00
Tienson Qin
b7d9098e80 Move gp-util and gp-config to the common dep 2024-01-03 16:38:05 +08:00
Gabriel Horner
f7e890b662 enhance: dev command to update db graph with its db.sqlite 2023-12-20 17:02:02 -05:00
Tienson Qin
aff14668fc Add page rename tests 2023-12-04 18:15:47 +08:00
Gabriel Horner
e95531869a chore: move db only property util fns to their own ns
by doing this found a couple places where we accidentally called db fns
in file graph contexts
2023-11-17 16:36:49 -05:00
Tienson Qin
6a47648c6c Replace enum type with available choices (#10438)
* Add type schema for enum values

* Refactor: closed values instead of enum to limit values

There's no need to add the enum type, we just want to limit the
values.

* feat: :page type supports closed values

* fix: can't set property values for text/number types

* fix: don't trigger on-chosen when unmounting any select component

* fix: can't apply both page classes limitation and closed values

* fix: merge conflicts

* fix: ui not refresh when changing closed value

* fix: can't set icon for closed value
2023-11-14 18:48:34 +08:00
Gabriel Horner
d656c75428 fix: improve property type ux by locking once property is used
fixes LOG-2900. Also fixed lint
2023-11-13 10:05:54 -05:00
Gabriel Horner
3ec7492abd fix: some queries failed since DB graphs don't have :block/file
One query was failing to load namespaced pages since datascript
fails hard for reverse lookups or {...} syntax on non-existent
attributes.
Also disabled or logged queries that don't have an equivalent
yet for DB graphs
2023-10-27 22:30:39 -04:00
Gabriel Horner
3f773ed876 fix: update all db graph uses of mldoc to use db config
Left a few uses of gp-mldoc/default-config but only in file graph
specific locations or functionality that wasn't related to db graphs
e.g. handler. plugin. Also removed format/get-default-config as it was unused

Part of LOG-2741
2023-10-27 14:08:55 -04:00
Tienson Qin
9c251ff413 fix: hidden page names displayed in references or query results
ref LOG-2854
2023-10-26 21:54:23 +08:00
Gabriel Horner
82c49bb420 Update page deletion messages so page content deletion is expected
Part of LOG-2733
2023-10-26 09:28:11 -04:00
Tienson Qin
3b9361d617 enhance: disable page deletion if it still has references
The page's blocks will be deleted though.
2023-10-26 17:15:08 +08:00
Gabriel Horner
211dd6aea7 enhance: disable preferred-format and setting org-mode
for db graphs. Also deprecate in config
2023-10-24 17:15:05 -04:00
Gabriel Horner
231f5d7ac6 fix: setting config should update db not file
Fixes LOG-2748. Also fix config.edn being saved when invalid
which would result in confusing scenarios where an invalid config
could persist into other contexts like a settings change
2023-10-17 10:47:47 -04:00
Gabriel Horner
edaf9b286a chore: move frontend db namespaces to a dedicated parent ns
Moved these namespaces to logseq.db.frontend.* to make their purpose
explicit and make the namespaces easier to maintain
2023-10-16 17:24:51 -04:00
Gabriel Horner
4b0100cb25 chore: cleanup page-property file based ns
All of frontend.util.page-property was file based except for one line.
Moved that ns to a file-based ns and moved the line out to the more
appropriate property-handler
2023-10-02 15:59:43 -04:00
Gabriel Horner
fceb6ddb72 chore: split up page-handler into file-based, db-based and graph
Did this cleanup as I noticed that multiple fns were checking if they are in a
db context when they didn't need to. By organizing these namespaces, the
db and file versions will be easier to maintain.

While doing this refactor, I didn't change any logic except for removing
unnecessary db-based-graph? checks.  Also renamed a few fns to remove
redundant file- and db- prefixes
2023-10-02 14:32:02 -04:00
Gabriel Horner
c07da6cc80 Move handler.common.repo fn into sqlite-util
This makes create-graph* namespaces independent of frontend
as they should be to be used externally
2023-09-06 08:59:40 -04:00
Gabriel Horner
b264d17309 Move db-graph property fns to its own logseq.db ns
db-graph related fns like these shouldn't be in the graph-parser dep as
that dep should only really be used with file graphs as much as possible.
This is also being done in preparation for making the create-graph ns independent of
the frontend

Also db- prefixes in fns were dropped since the ns now carries the db-
prefix
2023-09-05 17:15:45 -04:00
Gabriel Horner
2327fa3103 Fix query table settings failing on click and enhance dev commands
to display properties as named maps
2023-08-22 16:18:21 -04:00
Gabriel Horner
9fff912f1e Improve on create graph script
- Split out reusable fns to their own ns
- Created graph now initializes all the same data as in the app
- Had to make a copy of block-with-timestamps for nbb compatibility
  and started using it in a couple places that are easy to QA
2023-08-20 02:38:53 -04:00
Andelf
1c6fe4be82 enhance(sync): add merge step to update local 2023-06-26 19:20:04 +08:00
Gabriel Horner
4c2e61cbd3 Remove deprecated :editor/command-trigger option
This option has been deprecated for a couple months
2023-06-02 11:49:08 -04:00
Andelf
51201124ff fix(fs): add unicode normalize to path-fn
This is a catch-all type fix
2023-05-18 12:24:18 +08:00
Gabriel Horner
b2776bbb18 Remove supported-formats in all the places it's no longer used 2023-05-11 13:56:25 +08:00
Junyi Du
8f647519b2 dev: diff-merge error capturing, with unit test case 2023-04-17 09:41:39 -04:00
Junyi Du
497284bd08 dev (doc): minor docstring updates 2023-04-17 09:41:39 -04:00
Junyi Du
5aba871ead deps: diff-merge
dev: graph parser IoC hook

test: use test db for diff-merge tests

fix: ci lint

dev: refactoring post block-parsing process

feat: diff-merge 2 way merge integration

fix: key namespace of uuid in fix-duplicated-id

fix: duplicated uuid ci
2023-04-17 09:41:39 -04:00
Gabriel Horner
a53ebf1750 Fix parse-graph namespace bugs
parse-graph didn't have all the extract-options that the app does.
Adding them fixed the bugs.
Also fix publishing bug where old :all-pages-public? option wasn't
respected
2023-04-14 09:35:55 -04:00
Andelf
a051ded28e refactor(fs): handle global config as state, not in db 2023-03-28 09:14:42 +08:00