Commit 676e6ca
committed
✨ feat(mq-lang, mq-markdown): Add table header selector support
This commit enhances table handling capabilities in mq by adding support for table header selectors:
- Added `is_table_header()` helper function to builtin.mq for checking table header nodes
- Extended `.table` selector in builtin.rs to match table header nodes when using `.table` without row/column parameters
- Added `is_table_header()` method to the Node enum in mq-markdown for type checking
- Included comprehensive test cases for table header selector matching scenarios
- Added documentation for `.table` and `.[]` selectors in BUILTIN_SELECTOR_DOC
This change allows users to select and manipulate table headers using the same `.table` selector syntax, improving consistency in table processing workflows.1 parent edffbb9 commit 676e6ca
File tree
3 files changed
+44
-1
lines changed- crates
- mq-lang
- src/eval
- mq-markdown/src
3 files changed
+44
-1
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
162 | 162 | | |
163 | 163 | | |
164 | 164 | | |
| 165 | + | |
| 166 | + | |
| 167 | + | |
165 | 168 | | |
166 | 169 | | |
167 | 170 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2643 | 2643 | | |
2644 | 2644 | | |
2645 | 2645 | | |
| 2646 | + | |
| 2647 | + | |
| 2648 | + | |
| 2649 | + | |
| 2650 | + | |
| 2651 | + | |
| 2652 | + | |
| 2653 | + | |
2646 | 2654 | | |
2647 | 2655 | | |
2648 | 2656 | | |
| |||
2683 | 2691 | | |
2684 | 2692 | | |
2685 | 2693 | | |
| 2694 | + | |
| 2695 | + | |
| 2696 | + | |
| 2697 | + | |
| 2698 | + | |
| 2699 | + | |
| 2700 | + | |
| 2701 | + | |
2686 | 2702 | | |
2687 | 2703 | | |
2688 | 2704 | | |
| |||
3712 | 3728 | | |
3713 | 3729 | | |
3714 | 3730 | | |
3715 | | - | |
| 3731 | + | |
3716 | 3732 | | |
3717 | 3733 | | |
3718 | 3734 | | |
| |||
4224 | 4240 | | |
4225 | 4241 | | |
4226 | 4242 | | |
| 4243 | + | |
| 4244 | + | |
| 4245 | + | |
| 4246 | + | |
| 4247 | + | |
| 4248 | + | |
| 4249 | + | |
| 4250 | + | |
| 4251 | + | |
| 4252 | + | |
| 4253 | + | |
| 4254 | + | |
| 4255 | + | |
| 4256 | + | |
| 4257 | + | |
| 4258 | + | |
| 4259 | + | |
| 4260 | + | |
| 4261 | + | |
| 4262 | + | |
4227 | 4263 | | |
4228 | 4264 | | |
4229 | 4265 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1382 | 1382 | | |
1383 | 1383 | | |
1384 | 1384 | | |
| 1385 | + | |
| 1386 | + | |
| 1387 | + | |
| 1388 | + | |
1385 | 1389 | | |
1386 | 1390 | | |
1387 | 1391 | | |
| |||
0 commit comments