Is there a theorem package that is modifiable and can be adapted to Spanish?

I’m looking for a theorem environment package that is modifiable and can be adapted to Spanish.

(I’m biased but) there is my package, theoretic – Typst Universe. To translate you’d have to go through all environments you care about and change the supplement:

#import "@preview/theoretic:0.3.1"
#import theoretic.presets.basic: * // or another of the preset styles
#show ref: theoretic.show-ref

#let theorem = theorem.with(supplement: "Teorema")
#let lemma = lemma.with( // etc

// your document here
1 Like

gracias.
Is there a possibility to play in

#rect()[#grid(columns:(5cm,1fr),[title][body]) ]

?

I’m sorry, i dont quite understand your question. But it might be that the columns preset is what you want?

You can then use the options block-args and grid-args to customize the frame and grid spacing. See the manual for details and examples

I’m also biased towards my package: alertoni. While the packages focus was more on the customizability than the manageability, you can still setup a reference-able system with it with a couple of code snippets:

#import "@preview/alertoni:1.0.0" as at

#at.new-type(name: "theorem", color: purple, icon: none, placeholder: [Use with `#theorem`])
#at.set-icons((theorem: none)) // needs to be called due to a bug, will be fixed in 1.1.0

#let my-style(title, icon, body, paint, height, width) = {
  rect()[#grid(columns:(5cm,1fr),[#title],[#body])]
}

#show figure.caption.where(kind: "theorem"): none
#let theorem(title: none, body, ..args) = {
  let number(n) = numbering("1", n) // To include section number: numbering("1.1",counter(heading).get().first(), n)
  figure(
    supplement: [Theorem],
    numbering: number,
    kind: "theorem",
    caption: title,
    at.callout(
      title: [Theorem #context number(..counter(figure.where(kind: "theorem")).get()) -- #text(weight: "regular", title)],
      body,
      type: "theorem",
      style: my-style,
      ..args
    )
  )
}

#theorem(title: [Good to know], lorem(10)) <theorem:good-to-know>
#theorem(title: [Another one], lorem(10))
You can reference @theorem:good-to-know above with `@theorem:good-to-know`.

#outline(title: [List of Theorems],target: figure.where(kind: "theorem"))


Note it’s not the best solution as it is just a workaround and limited to how the package works. But you can add your own style (see the manual)! I might create a function that just does all that similar to nleanba’s solution for the 1.1.0 release.

If you plan on using it, you will probably get a font warning. I recommend reading section “Installation” on installing the font.

Thank you. The columns preset contains what I requested.