mirror of
https://codeberg.org/forgejo/forgejo.git
synced 2024-12-23 20:17:03 +01:00
d67e9b9629
* SVG fixes Signed-off-by: jolheiser <john.olheiser@gmail.com> * Colorize span->svg only Signed-off-by: jolheiser <john.olheiser@gmail.com> * @silverwind suggestions Signed-off-by: jolheiser <john.olheiser@gmail.com> * Alphabetical Signed-off-by: jolheiser <john.olheiser@gmail.com> * Convert suburl and staticPrefix to window.config Signed-off-by: jolheiser <john.olheiser@gmail.com> * De-structure Signed-off-by: jolheiser <john.olheiser@gmail.com> Co-authored-by: Antoine GIRARD <sapk@users.noreply.github.com>
5 lines
240 B
JavaScript
5 lines
240 B
JavaScript
const { StaticUrlPrefix } = window.config;
|
|
|
|
export function svg(name, size) {
|
|
return `<svg class="svg ${name}" width="${size}" height="${size}" aria-hidden="true"><use xlink:href="${StaticUrlPrefix}/img/svg/icons.svg#${name}"/></svg>`;
|
|
}
|