Skip to content

Bases Formulas Support for VIEW fields #639

@Mistmage

Description

@Mistmage

Please fill out these Check-boxes

  • I checked for existing similar feature requests
  • I have read the docs and checked that the feature I am requesting is not already implemented
  • My feature request consists of only one feature

Is your Feature Request related to a Problem or Annoyance?

If i have

html(
  "<span style='font-size:24px; color:" +
    if(Rank<=3, "#CD7F32",

        if(Rank<=6, "#C0C0C0",

            if(Rank<=9, "#FFD700",

                "#a570f5"
              )
            
          
        )
      
    ) +
  "'>" +
    if(Rank==Rank.floor(), 
      "✦".repeat((Rank-1) % 3 + 1) +
      "✧".repeat(3 - ((Rank-1) % 3 + 1)),
      "✧✧✧"
    ) +
  "</span>"
)

style formula, i don't see a way to render an equivalent inline using MetaBind without JS.

(it takes a number and produces ✦✧✧ <span style="font-size: 24px; color:#a570f5">✦✧✧</span>)

Describe the Feature you'd like

Add support for formulas inside of the View.

Alternatives

As it is probably too much, as MetaBind uses different logic, just enhancing with some functions is also an option.

Additional Context

https://forum.obsidian.md/t/display-formulas-inline/108400/3

Metadata

Metadata

Assignees

No one assigned

    Labels

    feature requestNew feature or requestwaiting on upstream changethere is an upstream change that needs to happen before this can be worked on

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions