The New Super-Simple Way to Theme Angular Material (v19)

Поділитися
Вставка
  • Опубліковано 21 січ 2025

КОМЕНТАРІ • 37

  • @joewhite6300
    @joewhite6300 Місяць тому +2

    Great explanation of this! Thank you

    • @ZoaibKhan
      @ZoaibKhan  Місяць тому

      Hey Joe! Glad you liked it :)

  • @awunnenb
    @awunnenb 13 днів тому

    You have helped me a lot. Thank you very much!

    • @ZoaibKhan
      @ZoaibKhan  12 днів тому

      You're welcome and glad to have helped :)

  • @DirtySouth33T
    @DirtySouth33T Місяць тому +1

    glad you touched on this! lol thanks brother! I am going to have to change tailwind and things like that to now include --mat- var

    • @ZoaibKhan
      @ZoaibKhan  Місяць тому

      Oh, let me know how it goes!

  • @tarun8987
    @tarun8987 Місяць тому

    Great Job 👏🏻 Really very helpful and informative 〽️

    • @ZoaibKhan
      @ZoaibKhan  Місяць тому

      Glad you liked it! 👍

  • @thechaoslp2047
    @thechaoslp2047 Місяць тому +1

    Hello, I have a question
    How can I use the different shades of the color palette provided by angular?
    Like azure, cherry etc.
    Before you had a function for it, but i cannot get it to work
    Like for example I want to use the 500 shade of the mat.azure color in my scss how can I do that?
    Thank you

    • @ZoaibKhan
      @ZoaibKhan  Місяць тому

      Not really sure, because there is no mention of this in the guides. I'm sure there must be an easy way to do it in Sass - but not that great of a Sass guy myself :)

    • @thechaoslp2047
      @thechaoslp2047 Місяць тому +1

      @ZoaibKhan hi, yes - its been a bit frustrating since the official docs don't explain this at all

  • @shna5400
    @shna5400 6 годин тому

    Thanks for the video! I have one question: How do you create a theming config variable to pass to components? In that case, should we use mat.define-theme?

  • @cortesdopixelblock5389
    @cortesdopixelblock5389 14 днів тому

    hy, can you use mixins to change color pallet in realtime? or i have to rebuild every theme and apply a reset to change the colors to do so? can you explain if this cand be done? sorry about my english

    • @ZoaibKhan
      @ZoaibKhan  14 днів тому

      Both mixins and color palettes are used at compile time only, so that would be a no for realtime. But the mixin emits the CSS color system variables - so you can change those at runtime pretty easily.

    • @dieIcelimo
      @dieIcelimo 12 днів тому

      ​@@ZoaibKhan First of all, thx for the video! I have the same issue. How is it possible to set these variable at runtime? Can you give a short explanation?

    • @dieIcelimo
      @dieIcelimo 12 днів тому +1

      Got it myself. Its actually quiet simple, as you said: document.documentElement.style.setProperty('--mat-sys-primary', '#00ff00');

    • @ZoaibKhan
      @ZoaibKhan  12 днів тому +1

      @@dieIcelimo Great! Yup, they are just simple CSS variables - so can be overriden at any level in the app :)
      I also have a short summary of a longer video I did on all the system variables in material and how I created a dark theme switcher using them. You might find it useful
      ua-cam.com/video/5toEyMTcTr8/v-deo.html

  • @codeme8016
    @codeme8016 Місяць тому

    Beautiful! Thanks a lot!

    • @ZoaibKhan
      @ZoaibKhan  Місяць тому

      Glad you like it! :)

  • @karvan101
    @karvan101 Місяць тому

    Could you please share the code for switching???

    • @ZoaibKhan
      @ZoaibKhan  28 днів тому

      Yup, here you go:
      github.com/thisiszoaib/angular-dark-mode

  • @Wexo
    @Wexo 9 днів тому

    Thanks for the explanation. I don't understand, why we don't at least get the primary / secondary / ... colors as css classes out of the box, but i guess that's the material way. Here's hoping they are done with breaking changes and reinventing the wheel every 1-2 years with Version 3...

    • @ZoaibKhan
      @ZoaibKhan  9 днів тому

      yeah, the no color variants thingy is flowing from material design 3 specs. Me hoping for the same 😄

  • @chikna_engr
    @chikna_engr Місяць тому

    Should we start learning with angular 12/13/14
    or
    we should start learning angular 18and 19

    • @ZoaibKhan
      @ZoaibKhan  29 днів тому

      Angular 18 would be a good version to start with. Unless you have a legacy application in earlier versions

  • @hamzasheikh1370
    @hamzasheikh1370 29 днів тому

    Really very helpful to me . can you please make a short video for typography also dynamic fonts size changes setting for dashboard or across application so admin can change font type and size Thanks

    • @ZoaibKhan
      @ZoaibKhan  28 днів тому

      Hmm, that's an interesting idea. Let me take a look and see if I can come up with something

  • @satheshkumar5906
    @satheshkumar5906 2 дні тому

    great thanks for the video, can u make a video on adding custom colours Palettes instead of Prebuilt Color Palettes ?

  • @vrkv380
    @vrkv380 Місяць тому +1

    Please add an example with material theme and tailwind

    • @ZoaibKhan
      @ZoaibKhan  Місяць тому

      There is already a video on it. Check in my videos

  • @chikna_engr
    @chikna_engr Місяць тому

    Could you please start the angular tutorials series from basics to advance or make any type of dashboard application UI only that we can follow and understand how things works

    • @ZoaibKhan
      @ZoaibKhan  29 днів тому +1

      Check out my customizable dashboard series where we build a dashboard from scratch

    • @chikna_engr
      @chikna_engr 29 днів тому

      ​@@ZoaibKhan Could you please make a playlist of videos in your channel as i cant find as structure wise
      could you please make it in one playlist tab It could be named as Angular Dashboard from start to end for begginer
      as i dont know which video should i start with first and so on till the end

    • @ZoaibKhan
      @ZoaibKhan  29 днів тому

      Here's the playlist for the dashboard - it includes all of the videos related to it in sequence. This playlist is also shown on my main channel page.
      ua-cam.com/play/PLHbz-DWIAPJAUZSossNgj6-ds1MwSL2f_.html

  • @vrkv380
    @vrkv380 Місяць тому

    Please add custom theme demo example

    • @ZoaibKhan
      @ZoaibKhan  Місяць тому

      Yes, I will in future videos, hopefully soon!