generated from t/malachite
add: user profiles and junk
This commit is contained in:
parent
6b8c33d27f
commit
2bd23f8214
28 changed files with 1139 additions and 108 deletions
|
|
@ -55,6 +55,10 @@
|
|||
(text "{{ icon \"ellipsis\" }}"))
|
||||
(div
|
||||
("class" "inner surface")
|
||||
(button
|
||||
("class" "button surface")
|
||||
("onclick" "edit_message_ui('{{ message.id }}')")
|
||||
(text "edit"))
|
||||
(button
|
||||
("class" "button surface red")
|
||||
("onclick" "delete_message('{{ message.id }}')")
|
||||
|
|
@ -63,6 +67,55 @@
|
|||
|
||||
(div
|
||||
("class" "body no_p_margin")
|
||||
("id" "{{ message.id }}_body")
|
||||
(text "{{ message.content|markdown|safe }}"))
|
||||
(text "{{ self::avatar(id=message.owner) }}"))
|
||||
(form
|
||||
("class" "body hidden flex flex_row gap_ch")
|
||||
("id" "{{ message.id }}_edit_area")
|
||||
("onsubmit" "edit_message('{{ message.id }}', event)")
|
||||
(textarea
|
||||
("name" "content")
|
||||
("required")
|
||||
(text "{{ message.content|safe }}"))
|
||||
(button
|
||||
("title" "Save")
|
||||
("class" "button")
|
||||
(text "{{ icon \"check\" }}")))
|
||||
|
||||
(a
|
||||
("href" "/@{{ message.owner }}?redirect=true")
|
||||
("target" "_blank")
|
||||
(text "{{ self::avatar(id=message.owner) }}")))
|
||||
(text "{%- endmacro %}")
|
||||
|
||||
(text "{% macro theme(user, theme_preference) -%} {% if user %} {% if user.settings.theme_hue -%}")
|
||||
(style
|
||||
(text ":root, * {
|
||||
--hue: {{ user.settings.theme_hue }} !important;
|
||||
}"))
|
||||
|
||||
(text "{%- endif %} {% if user.settings.theme_sat -%}")
|
||||
(style
|
||||
(text ":root, * {
|
||||
--sat: {{ user.settings.theme_sat }} !important;
|
||||
}"))
|
||||
|
||||
(text "{%- endif %} {% if user.settings.theme_lit -%}")
|
||||
(style
|
||||
(text ":root, * {
|
||||
--lit: {{ user.settings.theme_lit }} !important;
|
||||
}"))
|
||||
(text "{%- endif %}")
|
||||
(div
|
||||
("style" "display: none;")
|
||||
(text "{{ self::theme_color(color=user.settings.theme_color_surface, css=\"color-surface\") }} {{ self::theme_color(color=user.settings.theme_color_text, css=\"color-text\") }} {{ self::theme_color(color=user.settings.theme_color_text_link, css=\"color-link\") }} {{ self::theme_color(color=user.settings.theme_color_lowered, css=\"color-lowered\") }} {{ self::theme_color(color=user.settings.theme_color_text_lowered, css=\"color-text-lowered\") }} {{ self::theme_color(color=user.settings.theme_color_super_lowered, css=\"color-super-lowered\") }} {{ self::theme_color(color=user.settings.theme_color_raised, css=\"color-raised\") }} {{ self::theme_color(color=user.settings.theme_color_text_raised, css=\"color-text-raised\") }} {{ self::theme_color(color=user.settings.theme_color_super_raised, css=\"color-super-raised\") }} {{ self::theme_color(color=user.settings.theme_color_primary, css=\"color-primary\") }} {{ self::theme_color(color=user.settings.theme_color_text_primary, css=\"color-text-primary\") }} {{ self::theme_color(color=user.settings.theme_color_primary_lowered, css=\"color-primary-lowered\") }} {{ self::theme_color(color=user.settings.theme_color_secondary, css=\"color-secondary\") }} {{ self::theme_color(color=user.settings.theme_color_text_secondary, css=\"color-text-secondary\") }} {{ self::theme_color(color=user.settings.theme_color_secondary_lowered, css=\"color-secondary-lowered\") }} {% if user.permissions|has_supporter -%}")
|
||||
(style
|
||||
(text "{{ user.settings.theme_custom_css|remove_script_tags|safe }}"))
|
||||
(text "{%- endif %}"))
|
||||
(text "{%- endif %} {%- endmacro %} {% macro theme_color(color, css) -%} {% if color -%}")
|
||||
(style
|
||||
(text ":root,
|
||||
* {
|
||||
--{{ css }}: {{ color|color }} !important;
|
||||
}"))
|
||||
(text "{%- endif %} {%- endmacro %}")
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue