0
Fork 0
mirror of https://github.com/penpot/penpot.git synced 2025-02-03 04:49:03 -05:00
penpot/frontend/uxbox/shapes.cljs

12 lines
322 B
Clojure

(ns uxbox.shapes
(:require [sablono.core :refer-macros [html]]))
(defmulti render
(fn [shape & params]
(:type shape)))
(defmethod render :builtin/icon
[shape & [{:keys [width height] :or {width "500" height "500"}}]]
(let [content (:svg shape)]
(html
[:svg {:width width :height height} content])))