Coder Social home page Coder Social logo

Comments (4)

jeromelaban avatar jeromelaban commented on June 29, 2024

What's the impact of setting material last (other than working around the issue)?

from uno.gallery.

agneszitte avatar agneszitte commented on June 29, 2024

What's the impact of setting material last (other than working around the issue)?

cc @kazo0, @Xiaoy312

from uno.gallery.

Xiaoy312 avatar Xiaoy312 commented on June 29, 2024

dont we always initialize XamlControlRsources first?
the obviously impact is the default control styles, since the last initialized library will contribute first
also didnt we went over this last time, and there are problem no matter which gets initialized last? either fluent style or material style is broken depending on the order.

from uno.gallery.

kazo0 avatar kazo0 commented on June 29, 2024

Two paths:

  1. Material -> Fluent and then we re-init Material in the MaterialContentPresenter for the SamplePageLayout here This is our current method
  2. Fluent -> Material and then we re-init Fluent in the FluentContentPresenter for SamplePageLayout here

With Option 1 we are re-initializing the lesser of two evils since I would assume MaterialToolkitTheme is less heavy than XamlControlsResources (right?). Downside is we aren't using Material by default for the styling of the outer shell of the application, so we may run into issues similar to what we originally had if we were to start using CheckBoxes/RadioButtons/etc. outside of just the sample areas.

With Option 2 we are re-initializing XamlControlsResources, which is probably pretty large. Although, it would probably be re-initialized less often as Material is usually the default tab to be loaded when opening up sample pages (actually not sure if the resource would be loaded regardless or only if the contentpresenter's visibility changes to visible?). Upside is that Material is the default styling for the entire application in this case

After doing a quick test, the problem we are seeing here is avoided if we initialize Material last (Option 2)

Material on page load
image

If I switch to Fluent
image

I'm good with swapping the order but this still doesn't address why this isn't working specifically on mobile when you have a TemplateBound property that is set to an overridden ThemeResource

from uno.gallery.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.