Commit Graph

417 Commits

Author SHA1 Message Date
Andelf
8ed5b983b5 refactor(fs): unused mobile fs fn 2023-03-28 09:14:42 +08:00
Gabriel Horner
1d91b9cfd8 Add :page column for block results
As asked for in
https://discuss.logseq.com/t/add-pagename-field-to-the-list-of-table-fields-in-simple-query/15176/2
2023-03-24 10:16:00 -04:00
charlie
fc3e5ac59e refactor: utils for html5 media formats 2023-03-24 10:13:37 -04:00
Tienson Qin
db6fc6b7ee feat: simple query builder (#8774)
Simple query builder

---------

Co-authored-by: Gabriel Horner <gabriel@logseq.com>
Co-authored-by: charlie <xyhp915@qq.com>
2023-03-21 14:27:00 +08:00
Gabriel Horner
7a905583cf Split raw and formatted paste to prevent future coupling bugs 2023-03-20 09:54:41 -04:00
Gabriel Horner
72298d23c8 Raw paste should only do basic pasting
Fix #6815 and fix #6142.
Raw paste used to do this before #5396 was introduced.
We accidentally coupled rich and raw paste starting at
999defdad1 which then caused these issues
2023-03-20 09:54:41 -04:00
Gabriel Horner
1c3ef2ccb5 Fix url? detection for raw paste case - fix #7297 2023-03-20 09:54:41 -04:00
rcmerci
3cda885b9b add unit-tests for export 2023-03-20 12:31:35 +08:00
rcmerci
6fae1a8c09 fix unit test 2023-03-20 12:31:35 +08:00
Gabriel Horner
05f6665d12 On normal paste wrap link in macro if possible
Remove warning for no macro wrapping as that is excessive warning
2023-03-15 18:27:52 -04:00
Gabriel Horner
dc7480b59a Fix test failing b/c it was coupled by forgetting to reset
Also fix other tests that don't reset
2023-03-15 18:27:52 -04:00
Gabriel Horner
e8dd8a679e Add test for raw url paste fix 2023-03-15 18:27:52 -04:00
Gabriel Horner
91e89ef2d6 Chore: Add deprecation for :editor/command-trigger config (#8720)
* Add deprecation for :editor/command-trigger config

* enhance: warning dialog

* enhance: notification styles

* enhance: notification icons

* Fix tests after config warning improvements

---------

Co-authored-by: Konstantinos Kaloutas <konstantinos@logseq.com>
2023-03-04 12:07:33 +08:00
sallto
fd3afacabf test: add test for duplicate key error msg 2023-03-02 16:04:20 -05:00
Zhizhen He
25c15053d6 feat: add typos to GitHub action
Signed-off-by: Zhizhen He <hezhizhen.yi@gmail.com>
2023-02-21 12:01:58 -05:00
megayu
a4a5758afc enhance: paste from clipboard (#8642)
replace the selected part from the clipboard
instead of formatting it to a link if it's within the link
2023-02-21 15:55:59 +08:00
rcmerci
2a12ffc331 feat(editor/copy-paste): refactor copy/export in cljs (#8530)
Huge performance improvement for copy and export

Refactor copy/export in cljs instead of Mldoc
2023-02-20 23:08:58 +08:00
Gabriel Horner
350323ad19 Fix property values not autocompleting full ref values
Page refs and tags were not autocompleting their characters
which led to unreferenced completions
2023-02-13 15:34:26 +08:00
Gabriel Horner
818e735d7c Tag menu should stay open for multiple tags
Fixes #6805 and #8175
2023-02-13 15:34:26 +08:00
Gabriel Horner
32d23a7f44 Fix command and hashtag not triggering at start of a multi-line 2023-02-12 09:49:15 +08:00
Gabriel Horner
90003c0622 Move default case for keyup-handler out
Managing 10+ bindings in a fn is a recipe for bugs
2023-02-12 09:49:15 +08:00
Gabriel Horner
361e61efc7 Slash command closes after one space, fixes #5510 2023-02-12 09:49:15 +08:00
Gabriel Horner
475d4ce7d9 Fix command completion firing too often
Only fire at the beginning of a line or when starting a new word
2023-02-12 09:49:15 +08:00
Yichen Yan
a3c7308dc0 fix(query): cache special value as resolved value (#8263)
* fix(query): cache inputs as resolved values
Co-authored-by: Ben Yorke <ben@yorke.io>
2023-02-06 16:32:16 +08:00
Junyi Du
3b911c536c test: some more page name test cases 2023-02-03 15:35:28 +08:00
Gabriel Horner
917a8aa098 Fix page blocks not displaying full property values in query tables
We were only saving these in pre-block but we also need them in page
block. Also adds tests for blocks that had this behavior since #6529
2023-02-01 16:28:42 -05:00
Gabriel Horner
c0d81dd389 Remove debugging leftovers from test 2023-01-31 16:05:20 -05:00
Ben Yorke
c76da13570 Adds support for :query-page as an input 2023-01-31 16:05:20 -05:00
Gabriel Horner
78506f22d0 Fix deftests that have confusing args that only apply to defn
Follow up to #8412 where we're accidentally copying
invalid forms from other tests
2023-01-30 10:56:06 -05:00
Gabriel Horner
5ac1415726 Comments to describe unresolved behavior more explicitly 2023-01-20 16:19:19 -05:00
Gabriel Horner
8e47c327bf Merge branch 'master' into ben/advanced-queries-relative-date-input 2023-01-20 15:58:40 -05:00
Ben Yorke
f1568dbe24 Pull out testing function for more test abstraction 2023-01-20 18:19:55 +01:00
Ben Yorke
6d1f26fa03 Abstract out helper fn for timestamp react-query-tests 2023-01-20 18:14:54 +01:00
Ben Yorke
a2efbdb333 Add error test conditions 2023-01-20 13:07:29 +01:00
Ben Yorke
ba68a368f4 Add HHMMSS and HHMMSSmmm 2023-01-20 12:53:24 +01:00
Ben Yorke
b6c00254e8 Add tests for time related queries 2023-01-20 12:29:22 +01:00
Gabriel Horner
c804e051cc Add validation for repo config.edn
- Add test, task and schema for repo config.edn
- Also removed no longer needed temp fix
2023-01-18 10:07:52 -05:00
Ben Yorke
417630590a Add explicit tests for :+X-ms and :-X-ms 2023-01-18 14:40:12 +01:00
Ben Yorke
07f58f33d6 Refactor resolve-input to use simple query relative date syntax 2023-01-18 14:08:54 +01:00
Ws
4c33ff05fc fix(zotero): Missing PDF caused by incomplete linked file path. (#7676)
Resolve #6771 #6503
Introduced by #5995

Co-authored-by: Junyi Du <junyidu.cn@gmail.com>
Co-authored-by: Andelf <andelf@gmail.com>
2023-01-17 11:23:19 +08:00
charlie
e70d76589b enhance(pdf): make the weblink pdf filename to be human-readable for the annotations page 2023-01-12 21:04:12 +08:00
Gabriel Horner
ba69f13d34 Allow :rules and built in rules usage
Fixes #8250 and fixes #7201
2023-01-11 11:59:18 -05:00
Gabriel Horner
17f51c7b77 Make resolve-input nbb compatible
- Brought back Xd-{before,after}-ms and tested it
- Move it to its own ns in graph-parser
- Updated nbb-logseq in deps/
- Made db-utils alias consistent
- Organized resolve-input
2023-01-07 02:49:07 -05:00
Gabriel Horner
506faa89c7 Add tests for :current-block and :parent-block
Remove before-ms and after-ms if we don't have a good use case for it
2023-01-07 02:49:07 -05:00
Gabriel Horner
b6abd05a97 Fix inconsistent page links for web/publishing
When coming from search, page links were capitalized but most everywhere else
page links were lower case. This fix consistently enforces lower case
2022-12-22 12:47:33 +08:00
rcmerci
31e6c2c2df fix lint 2022-12-20 17:22:52 -05:00
rcmerci
5287c24cf2 add testcase for get-block-children-ids-in-db 2022-12-20 17:22:52 -05:00
Guy Pursey
6618c1228d Fix: query table sorting (#7751)
* test: sorting for mixed type block properties

* test: edited integer sorting test

Wanted to ensure it included a case where the sorting would
behave different if the numbers were coerced to strings.

In that case, "77" would precede "8" whereas for integer sorting
we want "8" to precede "77".

Renamed `:rating` to `:integer` to reflect this new scenario.

* test: new decimal number test

* test: query table sort semver-style string block properties

* test: query table sort positive and negative integers

* fix: replace separate sort strategies with natural sorting strategy

* fix: comparing only numbers in query table sort

* test: consolidate query table sort integer tests

* format: removed line breaks and consolidated small comparison lines to pass large-vars lint

* Tweaks to PR

- use reader literal for js
- Bring back readability to test, each case should have whitespace
  between it. Split up deftest at a natural spot as deftest exceeds
  reasonable size of a large var

Co-authored-by: Junyi Du <junyidu.cn@gmail.com>
Co-authored-by: Gabriel Horner <97210743+logseq-cldwalker@users.noreply.github.com>
Co-authored-by: Gabriel Horner <gabriel@logseq.com>
2022-12-20 17:02:03 -05:00
Tienson Qin
3e71b1d6f3 fix: db/entity with interger id is not nil with non-exist block (#7723)
fix: returns nil for db/entity if the entity doesn't exist

Co-authored-by: Junyi Du <junyidu.cn@gmail.com>
2022-12-16 00:21:42 +08:00
Gabriel Horner
10d6bc28da Switch named block links to autolink to header blocks
Replaced block property approach as it doesn't provide as much
functionality initially
2022-12-15 11:14:56 -05:00