Bases: Gallery View / Card View

Use case or problem

I love the new Bases-Feature! Great work and thanks for this! I paid for it, to support you a little bit!

I would like to have a gallery view like in Notion or Capacities. This would be a total game changer for me!

Notion:

Capacities:

Proposed solution

Would be great to have this + a number of entries, which is very useful / important / interesting too.

Related feature requests (optional)

bases-display-the-total-number-of-files-currently-visible-in-the-view

10 Likes

And the option to show properties as “Rating” or “Author” or something like this. As you can see on the pictures.

2 Likes

+1
Now that trakt.tv went to shit, this would be such a fantastic replacement.

see Trakt pricing announcement and some of the stupid changes made over the last year and a half or so

Will be implemented in V1.9.3

1 Like

I’m happy to see that I can use something like the following to use file.links to reference an image in a file like so:

filters:
  and:
    - tags.contains("file-with-images")
formulas:
  lastImage: file.links.slice(-1)
views:
  - type: cards
    name: Preview
    image: formula.lastImage
    cardSize: 120

But it would be really nice if file.links included more links. In the little testing I’ve done I can only see links of the form[[URL]]. It would be nice if it supported more links: ![[URL]] and [text](URL) (of course, I’ve got tons of notes where I only reference the linked image once using ![[URL]] syntax…and those don’t show up in bases :frowning: )

Use file.embeds.

1 Like

that is amazing, thank you!

Cover Images work with Formula

Image(Cover)

but the image has to be in the YAML like "[[12RulesforLife-JordanPeterson.png]]" on the Book Note

If your images are like mine for Dataview `!“[[12RulesforLife-JordanPeterson.png|150]]” then the function won’t work which is a real shame as most of my Book Covers are this way so I can use this DV Query.

TABLE cover as Cover
FROM "04 VAULT/Books" OR #Book
WHERE file.name != "Books Database"
      AND file.name != "Bookshelf 02 (E-H)"
      AND file.name != "Bookshelf 03 (I-P)"
      AND file.name != "Bookshelf 04 (R-S)"
      AND file.name != "Bookshelf 05 (T)"
      AND file.name != "Bookshelf 06 (U-Z)"
      AND file.name != "Automated Book Template"
      AND file.name != "Books"
      AND ((file.name >= "0" AND file.name <= "9") 
      OR (file.name >= "A" AND file.name <= "Z"))
SORT file.name ASC

You can get around it by creating a Card View targeting the File Location of the Book Cover but it wont see the Properties of the Book Note which is disappointing.

Interested to know if you guys have found a workaround to allow "![[12RulesforLife-JordanPeterson.png|150]]" ?

1 Like

Hello.

Dataview can display images from frontmatter without the exclamation mark, so a property without an exclamation mark can work for both Dataview and Bases:

Table
("![|100](" + image + ")") as Cover

For me, with Dataview being replaced by Datacore, and with Bases being faster, more stable, and with more developers maintaining it, I have decided to remove Dataview from my vault and to replace it with Bases, updating syntax where necessary (with VS Code). Just waiting for sum() in Bases before I remove the last few Dataview queries that I still use, and I will then delete Dataview from my vault.

Wonder if it is possible to use a formula in Bases to slice the value and omit the exclamation mark?

That’s what I’m considering atm. Do I just update all the exclamation mark links so it’s compatible with bases. Save me waiting for a work around or syntax change.

That’s a bold move. Over time I can see dataview becoming less relevant. I’m still on fence as some things display and work better in dataview. Bases will continue to add pressure though for dataview queries

1 Like

Hello.

I would cautiously do a test first of all to make sure I was happy with how data is handled, and then before making wholesale changes with VS Code or similar, I would make a copy of the vault so that I could reinstate it easily if things went wrong with a massive search and replace of hundreds or thousands of files.

For me, major plus points of Bases have been (1) the ease of embedding master queries / views in notes, and (2) the speed with which the queries update—much faster in my vaults than Dataview, which often needs to be forcibly refreshed.

With Dataview being replaced by Datacore (according to the developer), I thought that now would be a reasonable time to make the switch, given that my Dataview code would need to be replaced anyway. Long term, I plan to stick with the security and speed of development offered by Bases as a core plugin. I suspect that Bases will replace Dataview / Datacore for most users, given how simple it is to use and how much quicker it is than Dataview when refreshing data. Can’t help but wonder if the Dataview / Datacore developer will maintain the community plugins if (big if, I know) the demand for them dwindles. I have gone from around 25,000 Dataview queries (full- and inline queries) to about 30 Bases. My vault loads more quickly now, especially on my old iPhone, and it no longer freezes multiple times per day, which was entirely my fault for using too many Dataview queries in the past. Appreciate that other people with other needs will make different decisions.

1 Like

Good advice, at the moment I’m like looking at all my Vaults thinking Dataview is losing its relevance as the days go by thinking I need to focus on updating them soon. Holding off for more updates so I don’t fall into the trap again.

I feel this to be the case also. Especially now with Card view. They only have to start adding search and notion like look ups and it’s game over for DV and Datacore.

1 Like

As I sit here upgrading my YouTube Vault with a new base I picked up another thing that isn’t available (yet) that I know of

In my Dataview query I can easily show iFrames in a Dataview Table.
I can also easily exclude particular notes inside the query

TABLE without ID
  Rating AS "Rating",
  Video-URL AS "Video URL",
  file.link AS "File",
  Topics as "Topic",
  Creator as "Creator",
  tags AS "Tags",
  status AS "Status",
  date-added AS "Date-Added"
FROM "04 VAULT/YouTube"
WHERE file.name >= "0" AND file.name <= "9" 
OR (file.name >= "A" AND file.name <= "L")
AND file.name != "How to be happier in 5 steps - Laurie Santos"
AND file.name != "How to make change and learn - Dr K"
AND file.name != "HealthyGamerGG"
SORT file.name ASC

If I try to do the same with bases:

  1. The iFrame isn’t allowed yet inside a base cell
  2. I can’t exclude one note from the filter easily

Hello.

Don’t use iFrames or know anything about embedding them in Dataview or Bases.

But for excluding single files, what syntax are you using? Is it not similar to Dataview, along the lines of:

file.name != link("HealthyGamerGG")

This is something I have been using in my YouTube Vault for quite some time to make cool card like layouts like

For Dataview I use

AND file.name != "HealthyGamerGG"

Using file.name != link("HealthyGamerGG") would not work as anything that doesn’t equal that file shows in the Bases Results

Bases Docs

  • Cards layout displays each file as a card in a grid. The view settings allow you to optionally configure an image property, which can be an image URL or attachment link.

Currently card layouts are specific to Images only.

Image(Yaml-Value) is a function that can be used for images inside the Property Function but not the case for YouTube Videos (yet) or ![[image-link.jpg]] (yet)

Leaves me in a bit of a No Mans Land, so I’m building out what I can based on what I have and then when I’m ready to transition fully to bases (once it matures) it will be easier to switch off the old DV Queries

Hi.

In my local vault, I can filter out individual notes and get clean results, such as:

filters:
      and:
        - file.folder == "Films"
        - file.name != link("Cloud Atlas (2012)")

I would hope that the (and or) statements in your vault could be adjusted to get the results you want. Perhaps a new not-marked-as-solved thread on this forum or Discord – with sample code – would attract the help of people more in the know than me.

URLs and images are supported in Bases, as you mentioned, but I haven’t seen anything about iFrames. Again, perhaps a discrete thread (feature request?) on this forum or Discord would get more traction than this semi-closed thread. :four_leaf_clover:

You’re right, PEBKAC in this scenario

It’s the way the Filters are constructed

Any of the following are true creates OR conditions

Dropping another filter below the group creates an AND condition

Feature Request Threads would probably get more visibility compared to Discord as it’s more for insider discussion. I don’t think this feature exists at this time. Important to remember Bases is in Beta still and things are evolving every day.

1 Like

Recently, on Discord, Licat mentioned that HTML (iFrames etc) is not supported in Bases. Not clear if it will be supported natively, through an API, or not at all – nothing explicit currently on the roadmap for Bases. Expect you have already seen the above, but leaving it here for anyone else who reads this thread.