Navigation

    FusionAuth
    • Login
    • Search
    • Home
    • Categories
    • Recent
    • Popular
    • Pricing
    • Contact us
    • Docs
    1. Home
    2. Tags
    3. theme
    Log in to post
    • All categories
    • A

      UNSOLVED How to trim input fields
      Q&A • login theme • • a.hauck-groninger

      2
      1
      Votes
      2
      Posts
      73
      Views

      F

      Hi

      I just want to add +1 to this question, as we are in the exactly same position as a.hauck-groninger. Primarily, our users experience this when auto-filling a field on Android.

      Thanks from Denmark 😊

      Mathias

    • F

      UNSOLVED Custom theme deployment between environments
      Q&A • theme deployment application api docs • • fred.fred

      2
      0
      Votes
      2
      Posts
      77
      Views

      dan

      @fred-fred said in Custom theme deployment between environments:

      It looks like we can transport with the API using Theme Update Endpoints and sharing environment API keys so one environment can see the next environment to copy the themes over.

      Yes, that's what I'd recommend. You could have different API keys for each environment and have the script that promotes the theme pull the API key from a secrets store. Make sure you limit the API key to the themes endpoint.

      You also might be interested in this post: https://fusionauth.io/community/forum/topic/1306/parameterizing-themes which indicates how you can have the same theme files point to different resources in staging/prod/dev/etc.

    • dan

      Different base resources for an environment
      Q&A • theme environments customization • • dan

      2
      0
      Votes
      2
      Posts
      58
      Views

      dan

      The best way to do this is to put a value on the tenant.data object. From there you can access it in each theme.

      So, for the tenant in the dev environment, set tenant.data.assethost to dev.example.com. For the prod environment, set tenant.data.assethost to dev.example.com.

      Then, in your theme, you'd have something like this:

      <link rel="stylesheet" href="${tenant.data.assethost}/styles.css"/>

      The reason to use the tenant object is that it is available on every theme template.

      This does mean that your tenant configuration will differ slightly between environments. You can also replicate this field value between tenants if you are using multiple tenants.

    • dan

      Parameterizing themes
      Q&A • theme environments • • dan

      2
      0
      Votes
      2
      Posts
      83
      Views

      dan

      We don’t currently resolve any environment variables in the themes, or anything other than what is documented here: https://fusionauth.io/docs/v1/tech/themes/template-variables/

      But you can set variables in the Helpers template using assign that can be used in other templates. You could use a templating language like jinja to build the Helpers template at build time and then a script to load it during deploy. (Or even sed.)

      You can also create different themes (a dev theme, a qa theme) and assign them via scripts to the different environments (unsure if you are using different tenants to represent environments or different FusionAuth instances, but the concept is the same).

    • dan

      Determining which OAuth grant you are in within the themes
      Q&A • theme oauth grant • • dan

      2
      0
      Votes
      2
      Posts
      51
      Views

      dan

      The only two grants that are relevant to an interactive flow are the authorization grant, and the implicit grant.

      I don’t recommend you use the implicit grant at all, so that leaves only the authorization grant.

      If the authorization grant is happening, response_type will be code.

      If the authorization grant is occurring due to a device grant, the user_code variable will be set.

    • dan

      Custom themes for an application
      Q&A • theme application • • dan

      3
      0
      Votes
      3
      Posts
      79
      Views

      dan

      @dan This was delivered in 1.27.0

    • dan

      Customizing the freemarker theme templates
      Q&A • theme customization javascript • • dan

      2
      0
      Votes
      2
      Posts
      106
      Views

      dan

      You can put whatever you want in the theme pages, but it's a good idea to keep them lean so the user has a quick login experience. After all, most folks don't care about auth except when it doesn't work!

      You can optionally pass info in the state parameter, that will come back to the caller. This can be encoded JSON, as long as it is url safe. You will want to make sure that you don't put too much stuff in there, as there are URL length limits for browsers (though I learned that chrome has a URL size limit of 2MB!). Here's an example of using the state parameter for application state.

      Or if you have different applications and redirect URLs, then just gathering metrics on the URLs may give you insight into who is using login, and from where.

      Sort of depends upon what type of analytics you need.

    • dan

      Locked out due to template changes
      Q&A • theme troubleshooting • • dan

      2
      0
      Votes
      2
      Posts
      48
      Views

      dan

      This link is probably what you are looking for:

      https://fusionauth.io/docs/v1/tech/themes/#handling-failures

    • dan

      SOLVED How can I use a custom font when customizing my theme?
      Q&A • fonts theme customization • • dan

      2
      1
      Votes
      2
      Posts
      64
      Views

      dan

      In order to use a custom font within a publicly accessible FusionAuth template for a hosted deployment, pull the font from a CDN or other server hosting the font.

      FusionAuth doesn't have any persistent storage for custom theme assets. You can use any font you like as long as it can be included via a tag.

    • dan

      SOLVED Can FusionAuth host my images?
      Q&A • images theme customization • • dan

      2
      0
      Votes
      2
      Posts
      101
      Views

      dan

      No, we don’t provide any persistent store for assets like images, CSS files or favicons.

      You’ll need to just use accessible URLs in your theme for those assets.

    • U

      Social providers in Register web page
      Q&A • provider theme customization • • ulysse

      2
      0
      Votes
      2
      Posts
      122
      Views

      dan

      Hiya,

      The issue is that the identityProviders map needs to be populated for that login script to work, and the class behind this page doesn't provide that map. So for now I don't see a way to do this.

      There is an open github issue to allow identity providers to be displayed on the registration page. I'd suggest adding your use case to that issue: https://github.com/FusionAuth/fusionauth-issues/issues/554 and I'm happy to rename it to something more general. Alternatively you can file a new issue if you feel the use case is distinct enough.

    • dan

      Is there a way to upload images for custom login page themes?
      Q&A • theme login faq • • dan

      1
      0
      Votes
      1
      Posts
      101
      Views

      No one has replied

    • dan

      How do you assign a theme to an application?
      Q&A • theme faq application • • dan

      5
      0
      Votes
      5
      Posts
      144
      Views

      dan

      @fred-fred

      Hiya,

      In addition to what @maciej-wisniowski suggested, if you have a paid license you can now have application specific themes (one theme per application; if no application theme is specified, it defaults to the tenant).

      You can see how that works in the sandbox environment (sandbox.fusionauth.io). I believe that feature landed in 1.27.0.

      You can buy a licensed edition here.