GithubHelp home page GithubHelp logo

tgrosinger / advanced-tables-obsidian Goto Github PK

View Code? Open in Web Editor NEW
2.0K 13.0 75.0 1.51 MB

Improved table navigation, formatting, and manipulation in Obsidian.md

License: GNU General Public License v3.0

JavaScript 5.75% TypeScript 92.42% CSS 1.82%
obsidian-md obsidian-plugin

advanced-tables-obsidian's People

Contributors

calosliu avatar dziubanmaciej avatar hunterboerner avatar mikle-bond avatar tgrosinger avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

advanced-tables-obsidian's Issues

Use checkCallback in Commands

Use the new checkCallback in the addCommand calls to only show table editor commands when the cursor is in a table.

Add table action bar

Use doc.addLineWidget in codemirror (documentation) to add a popup below the current line when a hotkey is pressed. This widget will have the various table actions, such as aligning the column, moving the column or row, and changing formatting type.

This would be beneficial because it would be a single hotkey for users to remember instead of binding lots of hotkeys for each interaction. Users would still be able to bind individual actions to hotkeys if they choose.

Cells with emoji are not formatted properly

Describe the bug
A clear and concise description of what the bug is.

*Even after formatting, not everything is formatted.

To Reproduce
Steps to reproduce the behavior:

  1. Go to '...'
  2. Click on '....'
  3. Scroll down to '....'
  4. See error

Make a table, fill the cells, and do a format.
This bug occurs both with "format at cursor" and "format all tables".

Expected behavior
A clear and concise description of what you expected to happen.

All pipes to line up

Screenshots
If applicable, add screenshots to help explain your problem.

table1

Desktop (please complete the following information):

  • OS: [e.g. iOS] macOSX
  • Obsidian Version: [e.g. v0.9.10] (Settings β†’ About β†’ Current Version) 0.9.19
  • Advanced Tables Version: [e.g. 0.4.0] (Settings β†’ Third-party plugin β†’ Browse β†’ Advanced Tables β†’ currently installed) 0.7.0

Additional context
Add any other context about the problem here.

Include image

Please include image or animated gif what the plugins is doing.

Asian language support

Describe the bug
The padding does not properly align the tables when using an Asian language

To Reproduce
Steps to reproduce the behavior:

  1. Create a table.
  2. Type in an Asian language (I am typing in Japanese)
  3. Hit enter to align the columns
  4. See error (screenshots below)

Expected behavior
The lines designating the columns align properly when typing in an Asian language.

Screenshots
Without monospace font checked (default monospace font)
image

With monospace font checked
image

Desktop (please complete the following information):
OS: Windows
Obsidian version: v0.9.16
Advanced Tables Version: v0.6.0

Additional context
I haven't tested this on other Asian languages, only Japanese, but I would expect the issue to be the same with languages using different alphabets as well.

How to escape from table

If you start a document with a table, we're trapped. There's no practical way to get out of the table.

I can think of two relatively intuitive approaches to fix this:

  • A simple keyboard shortcut to modify Enter to work as "Obsidian Normal" would be very convenient. Shift-Enter or Ctrl/Cmd-Enter are common Enter key modifiers and seems ideal to add a normal line feed. (Shift-Enter conflicts less with Obsidian than Ctrl-Enter)
  • Or slightly less convenient but still okay. Pressing Enter when at the very beginning of a line (technically outside of the table) acts as a normal line feed. Just requires a couple backspaces or back-arrows before hitting Enter to exit a table (then delete the extra line of pipes).

My workarounds were navigating somewhere else, copy a couple lines, then come back and paste over the table to escape it. Then delete the copied junk. Eventually I discovered that I can backspace to the start of a line, type come characters, then press return. Then there's enough space to escape the table and delete the extraneous stuff. Or I could think ahead and make sure to add some line feeds before creating a table. But thinking ahead rarely happens ;)
(we shouldn't have to think ahead. tools that encourage flow is more important)

Thanks though. I really like this plugin. Great work!

Sorting rows by specified column

Pulling inspiration from org-mode tables, add the ability to sort table rows by a specified column.

This feature would operate on the row level. Each individual row will not change, just their order within the table.

Interested in this feature? Vote by leaving a πŸ‘ below.

When table overflows out of the visible area, insert row and delete row take two clicks

Describe the bug
When table overflows out of the visible area, insert row and delete row take two clicks. The first click moves the cursor to the end of the row and the second click performs the action.

To Reproduce
Steps to reproduce the behavior:

  1. Create table with width greater than the visible area
  2. Try to insert or delete row

Expected behavior
The row to be inserted or deleted

Screenshots
advanced-tables-issue

Desktop (please complete the following information):

  • OS: elementary OS
  • Obsidian Version: 0.9.10
  • Advanced Tables Version: 0.5.3

Strange behavior if "Open table controls toolbar" hotkey is pressed when it's already showing

Describe the bug
If you activate the "Open table controls toolbar" hotkey, and then repeat the keyboard shortcut- instead of doing nothing or toggling off, a dim row of --------------s is inserted above the toolbar area. This repeats as many times as you press the key, until you switch to another note, or toggle edit/preview mode. The area is non-clickable.

To Reproduce

  1. Make table
  2. click into table
  3. hit hotkey (⌘D in my case - I have customized it, but also tested with the default β‡§βŒ˜D)
  4. toolbar opens
  5. press hotkey again, and keep pressing it

Expected behavior
Toolbar should either do nothing, or toggle closed if hotkey is activated when already showing.

Desktop (please complete the following information):

  • OS: macOS 10.15.7
  • Obsidian Version: v0.9.11
  • Advanced Tables Version: 0.5.2

Screen recording (open larger)
tables

Table navigation overrides hotkeys

Describe the bug
If you have "Bind enter to table navigation" on in the plugin settings, it will overide other keybindings such as ctrl + Enter if you are in a table.

For example, I have ctrl + enter bound to "Open link under cursor in new pane", but if I attempt to open a link inside a table using this keybind, it will instead navigate me to the next row.

To Reproduce

  1. Go to Bind "Open link under cursor in new pane" to ctrl + enter via the hotkeys settings.
  2. Paste the following table into a new note:
| Test | Test     |
| ---- | -------- |
| Test | [[Test]] |
  1. Navigate the cursor (aka carrot?) "inside" the link.
  2. Press ctrl + enter.
  3. Observe how a new row is added to the table.

Expected behavior
The keybindings that are enabled via the advanced tables settings should not activate if a "special" key is pressed (eg shift, alt, ctrl).

Screenshots
I don't think it's necessary for this one! But if you want a gif I'm happy to provide one if asked =)

Desktop (please complete the following information):

  • OS: Ubuntu 18
  • Obsidian Version: 0.9.22
  • Advanced Tables Version: 0.5.6

Additional context
Thanks for the great plugin =) It's very intuitive and helpful.

Failed to load plugin table-editor-obsidian

Describe the bug
Plugin doesn't load - any help appreciated.

To Reproduce
Steps to reproduce the behavior:

  1. Install plugin
  2. Click on slider to enable plugin
  3. See popup "Failed to load plugin table-editor-obsidian"

Desktop (please complete the following information):

  • OS: macOS Big Sur on M1
  • Obsidian Version: v0.9.20
  • Advanced Tables Version: 0.7.0

Not quite working on a mac big sur.

Describe the bug
Features that are not working: shortcut keys (tab, enter, etc.), automatic resizing of columns as I'm typing.

Some Features that are working: add column, add row, ...

Desktop (please complete the following information):

  • OS: Mac OS Big Sur
  • hardware: macbook pro intel chip
  • Obsidian Version: 0.10.1
  • Advanced Tables Version: 0.7.0

disable ribbon icon for control toolbar

Is your feature request related to a problem? Please describe.
I would like to be able to disable the new ribbon icon for the control toolbar. If I dont need it, it looks much cleaner.

Describe the solution you'd like
Add an switch in the settings tab.

Aliases are recognized as dividers

Aliases on links are recognized as two different entries when put into a table & viewed in preview mode.

Steps to reproduce the behavior:

  1. Create a table
  2. Put in the value [[Name|Alias]]
  3. Switch to preview mode to view the table

The use of [[Name|Alias]] usually creates a link with an alias instead of its file name, instead it becomes two different entries when put into a table.

  • OS: Windows 10
  • Obsidian Version: v0.10.1
  • Advanced Tables Version: 0.8.0

Doesn't format well if a table is nested under a bullet

When having a nested table (to have table indented inside a bullet), the "prettiness" seems to have lost. It fails to have that nice format.

Can something be done about it from your side or is it an obsidian/markdown issue?

Thanks for the plugin :))

Turn the table into Kanban view

Is it feasible to turn the table into a Kanban view, or different board view like notion, either through Mermaid or through converting into an image?

Or maybe just turn a table into a different table using a specific column entries as column headings? So there will be the original table and a transformed "view"/table?

Error 404

Using: Table editor 0.3.2 / Obsidian 0.9.10 / Ubuntu 20.04.

After loading Table editor, the following error pops up in the console:

Failed to load resource: the server responded with a status of 404 (Not Found)
https://github.com/tgrosinger/table-editor-obsidian/releases/download/0.3.2/styles.css

Support for non-English language

Been trying this plugin for a while. Really handyπŸ‘πŸ»
Due to the font issue all non-English languages are not supported I assume. Just curious are there any plans for those languages in the future?
Thanks!

Monospace

Describe the solution you'd like
If a table is created, a monospace font should automaticly be selected

Hotkeys start blank

Describe the bug
I expected the default hotkeys referenced in the github to be initialized but instead they are all blank.
Literally not even a problem and easy to fix in like 5 seconds, but I felt it was right to throw it on the bug tracker

To Reproduce
Steps to reproduce the behavior:

  1. Download and activate
  2. Profit

Expected behavior
I expected Tab to start making a table right away, and for the other hotkeys to be bound

Screenshots
My Hotkeys
vs
Expected Hotkeys

Desktop (please complete the following information):

  • OS: Linux Mint 20
  • Obsidian Version: v0.9.17
  • Advanced Tables Version: v0.7.0

Extra Information
Something in general is being very odd with my Obsidian at the moment. I cant edit the hotkeys at all.
Will update after restart.

Support remark style tables

Using: Table editor 0.3.2 / Obsidian 0.9.10 / Ubuntu 20.04.

Using this test table:

HA | HB
--- | ---
Aaaaaaaaaa | Baaaaaaaaaaa

Selecting Format table at the cursor from the command palette does nothing.
I found no relevant message in the console.

Have toolbar stay visible or right click available

Is your feature request related to a problem? Please describe.
As an idea, have the toolbar stay visible (floating at bottom of table, or under current row) or able to appear with a right-click.

Additional context
When I click to have the toolbar appear, it works, then when I do anything else, it disappears and I have to ask for it again.

Wrap cell content when using readable line length mode

Is your feature request related to a problem? Please describe.
I quite often have a lot of text in tables. In conjunction with readable line length it does not adapt to it but instead continues indefinitely in edit mode.

Describe the solution you'd like
I would like the content of the cells in edit mode to wrap just like normal text in Obsidian does so that the width of the page is not exceeded.

Describe alternatives you've considered
No alternatives I can think of.

Additional context

[[ internal links | aliases ]] issue in tables' columns

Thanks for the amazing plugin, if it wasn't for this awesome plugin I was still going to emacs to create tables. Really happy to be able to make great tables from Obsidian.

I discovered an issue when it comes to using links with aliases inside links. in the form of something like: [[2020-11-25|today]]

here's an example table that works without any issues.

| day            | mood    |
| -------------- | ------- |
| [[2020-11-22]] | 5/5     | 
| [[2020-11-23]] | 4/5     | 
| [[2020-11-24]] | 5/5     | 
day mood
[[2020-11-22]] 5/5
[[2020-11-23]] 4/5
[[2020-11-24]] 5/5

but if I use this format [[2020-11-25|today]] with the | vertical line, the table confuses it for a table division line.

Expected Behaviour

this is how I would like the table to format the last row.

| day                   | mood    |
| --------------------- | ------- |
| [[2020-11-22]]        | 5/5     | 
| [[2020-11-23]]        | 4/5     |
| [[2020-11-24]]        | 5/5     |
| [[2020-11-25|today]]  |         |

Current Behaviour

but currently, after pressing tab to format things the today]] section gets' split into the wrong column.

| day            | mood    |
| -------------- | ------- |
| [[2020-11-22]] | 5/5     | 
| [[2020-11-23]] | 4/5     | 
| [[2020-11-24]] | 5/5     | 
| [[2020-11-25   | today]] |
day mood
[[2020-11-22]] 5/5
[[2020-11-23]] 4/5
[[2020-11-24]] 5/5
[[2020-11-25 today]]

Specs

Linux Manjaro XFCE
Obsidian 0.9.17
Advanced Tables Version: 0.6.2


Edit

After thinking about it, this might not be a bug, but more of a request. (Feel free to relabel it)

Since this is something that would happen with tables inside of Obsidian without the plugin. If anything is more of a conflict of syntax.

Would really appreciate it if there was a way to work around this issue from within the plug in.

Thank you so much

shift+enter should insert newline

When in a table, the enter key is used to insert a new row. Sometimes however, it is desirable to insert a new line that is not a part of the table, for example to leave the table at the end of the document.

Also look into the escape table function in md-advanced-tables.

Format all tables in a note

Is your feature request related to a problem? Please describe.

I have a template with a number of tables in it. If I want to prettify all the tables I have to put my cursor in every one of them in turn and use the plug-in command "Format table at cursor".

Describe the solution you'd like

To be able to prettify all the tables in the note in 1 go, like with a hotkey.

Create release action

Move the functionality of the release.sh script into a Github action run automatically on tags.

Not recognizing simple tables

I have a table with the following structure

a | b | c
-|-|-
d | e | f

It renders fine on Obsidian (and Github)

a b c
d e f

But when I click the plugin button it says Cursor must be in a table, with the cursor in the table or even in a cell, both in edit and preview mode.

I use Windows 10, Obsidian v0.9.10, Advanced Tables 0.5.5

Table keybindings do not work

I am on Manjaro Linux with Obsidian 0.9.10

For me the default keybindings ( for next cell; for next row etc.) do not work, that is to say they do what I expect them to do outside of a table (indent; insert line break etc.)

Using the command palette, the functions themselves work well.

Emoji break the column alignment

NOT A HUGE ISSUE but...
Emoji break the column alignment in edit mode. In preview the tables look perfect.

To Reproduce

  1. Insert an emoji in any column
  2. Hit tab or enter
  3. Observe the misaligned columns

Desktop:

  • OS: Mac OS
  • Obsidian Version: 0.10.3
  • Advanced Tables Version: 1.4.11

The toolbar should account for cursor movement

Describe the bug

If the cursor moves while the toolbar is open, the toolbar actions need to account for the new cursor location. This would be preferable to just closing the toolbar when the cursor moves because it would be a step in the right direction of a persistent toolbar.

org-mode style table formulas

Add support for table functions which update the values of specific cells using values from the table. Inspiration will be pulled from org-mode tables to avoid reinventing the wheel.

This is the parent ticket for spreadsheet capabilities. See these issues for specific features:

Interested in this feature? Vote by leaving a πŸ‘ below.

Can't activate? 0.9.11

Describe the bug
Plugin is installed & enabled, but does not seem to be active...

To Reproduce

  1. install plugin in Obs 0.9.11
  2. try to use it

Expected behavior
extra table tools appear when cursor is in table cell

Screenshots
image

image

image

image

Desktop (please complete the following information):

  • OS: macOS 10.15.7
  • Obsidian Version: 0.9.11
  • Advanced Tables Version: 0.5.2

Autocompleting a tag in a cell jumps to the next row

Describe the bug
If I enter a tag by typing #tagname and using the autocomplete feature like #tagn<enter> (hitting enter to use the displayed tag), the cursor jumps to the next row.

To Reproduce
Steps to reproduce the behavior:

  1. Open a new file
  2. Add a the tag #tagbugin the beginning of the document
  3. Create a table
  4. Start typing the added tag from step 2 like this #tagb
  5. Hit <enter> key

Expected behavior
The cursor should stay in the current cell.

Desktop (please complete the following information):

  • OS: Linux (Arch Linux)
  • Obsidian Version: v0.9.10
  • Advanced Tables Version: 0.5.5

Table Caption

Is your feature request related to a problem? Please describe.
Much like in academic papers a table sometimes should have a caption to identify it more clearly.

Describe the solution you'd like
Create the <caption>This is a caption</caption> automatically

Describe alternatives you've considered
Another way is using a text expander; this is what I'm currently doing:

||||
|---|---|---|---|---|
|||||
|||||
|||||
|||<caption>This is a caption</caption>|  

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    πŸ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. πŸ“ŠπŸ“ˆπŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❀️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.