Shopify CSS Intro - How to Overwrite Theme Colors and Fonts When You Really Need To

แชร์
ฝัง
  • เผยแพร่เมื่อ 5 ส.ค. 2024
  • How to make precise design changes that go beyond what the theme settings allow. Get my book to learn more skills like this: edcodes.gumroad.com/l/diy-sho...
    This is one of the first videos I’m doing on CSS, because it explains when and where you should use CSS in your Shopify theme.
    In later videos I will be going more in-depth on CSS itself as a useful skill for Shopify store owners, as well as HTML, and finally Shopify Liquid.
    ===== Who am I? =====
    Hey! My name is Eduard.
    I teach the tech side of starting and running a Shopify store.
    Im a professional web developer, but my goal is to make Shopify easy with simple and straight-to-the-point videos.
    Visit my website: ed.codes
    ===== Stay Updated =====
    Want to see my latest tips, tutorials, and code add-ons? TH-cam won’t always show you. Subscribe to get emails directly from me: ed.codes/pages/newsletter
    ===== FAQ's =====
    My favorite Shopify Apps - ed.codes/blogs/resources/actu...
    My favorite Themes - ed.codes/blogs/resources/best...
    ===== Check out my Shopify Add-ons =====
    Pre-built sections & features for Shopify 2.0 themes, often replacing the need for apps. Copy and paste the code into your theme.
    edcodes.gumroad.com/
    ===== Join "Shopify DIY" Community on Discord =====
    Chat with me and other store owners and developers:
    ed.codes/community
    ===== Chapters =====
    00:00 Intro & Problem
    02:08 Create custom CSS file
    04:16 CSS basics recap
    08:17 Global change across all pages
    10:22 Changes in specific section types
    12:39 Changes in specific instance of a section using ID
    14:23 Change font sizes
    15:21 Checking current font size
    16:04 Change font sizes
    16:46 Cons of this method
    18:13 Pro tip - use comments!
    19:12 Why a separate CSS file
    20:07 CSS not working - understand specificity
    22:26 Worst case use !important
    23:29 Join Shopify DIY Discord
    #Shopify #CSS #coding

ความคิดเห็น • 84

  • @EdCodes
    @EdCodes  ปีที่แล้ว +1

    👋Hey! If you liked this video you will love my book: ed.codes/shopify-coding-handbook. It's full of practical advice for writing CSS in Shopify.

    • @isabella.v.
      @isabella.v. ปีที่แล้ว

      is there a way to change the way shopify sorts items on the shop page? the default is a-z which I find super annoying and doesn't make much sense for most, I guess. is this covered in the book by any chance? is it even possible? I would love to have it sorted by newest first by default

  • @WallArtFantasy
    @WallArtFantasy 2 ปีที่แล้ว +21

    This is literally the best and simple css tutorial videos I have ever come across. You are a lifesaver for real!! I wish I could have found this video earlier so I didn't have to spend hours to research the wrong info lol

  • @sphiwekunene7857
    @sphiwekunene7857 ปีที่แล้ว +7

    I love his tutorials cause they're so technical and practical. And it's hard to get this information anywhere else on youtube

  • @niqs4829
    @niqs4829 ปีที่แล้ว +1

    Your videos are the BEST honestly i have no knowledge of code and you make it so understandable thank you

  • @jeremyl9515
    @jeremyl9515 ปีที่แล้ว +1

    Thank you, Ed, I learn so much just from this one video, you make me feel somewhat empowered instead of complete hopelessness before I watched this video. 🙇🏼‍♂

  • @ishiedev1713
    @ishiedev1713 ปีที่แล้ว +1

    Your tutorial is excellent, providing a clear and concise explanation of fundamental CSS rules in a way that is accessible and easily comprehensible.

  • @skylineg6618
    @skylineg6618 ปีที่แล้ว +1

    This has so much without anything that felt like filler. I appreciate you so much. Thank you!

    • @EdCodes
      @EdCodes  ปีที่แล้ว

      Thanks! Check out my latest video it's also an intro to coding but much more structured - th-cam.com/video/5z2D7dLmhfk/w-d-xo.html

  • @buthy_88
    @buthy_88 ปีที่แล้ว +1

    You deserve more subscribers, man! Thanks

  • @carlosvargas2976
    @carlosvargas2976 ปีที่แล้ว +1

    Excellent video Ed!. I've searched everywhere for this and no one explains this as you do.

  • @darmar8609
    @darmar8609 ปีที่แล้ว +1

    Amazing tutorial, exactly what I needed help with! Thanking you Ed!

  • @TheClrr
    @TheClrr ปีที่แล้ว +1

    So much value in these 24 minutes. You are an excellent teacher. Thank you

  • @musafarrow701
    @musafarrow701 ปีที่แล้ว +1

    Very helpful video! Literally been looking around for this for ages everyone else keeps taking me to that stupid typography section which doesn’t help at all

  • @theupplife
    @theupplife ปีที่แล้ว +1

    It works, very easy, many thanks!

  • @oddBenji
    @oddBenji 2 ปีที่แล้ว +1

    That was amazing and so easy to understand it! Your teaching skills are cool!

  • @lexip.4269
    @lexip.4269 ปีที่แล้ว +1

    Thank you for this! I never realized that we could change the styling of elements using this way. Definitely subbed! Looking forward to learn from your upcoming videos :)

  • @heyitsjaredbender
    @heyitsjaredbender ปีที่แล้ว +1

    Dude I just found your channel and you are a champ!! I love your stuff - just subbed! Thanks for all the help and valuable info!

  • @mohitbeniwal3425
    @mohitbeniwal3425 2 ปีที่แล้ว +1

    you don't know how much time you saved for me
    I always pase call one by one because I don't know about custom CSS option
    that's really help me lot.
    and please keep making these type of videos really help a lot
    thank you so much Ed

  • @newtrinohair
    @newtrinohair ปีที่แล้ว +1

    What a fantastic tutorial thank you so much!

  • @asmrafar
    @asmrafar ปีที่แล้ว +1

    This was so helpful, thank you!!!

  • @jonward1314
    @jonward1314 2 ปีที่แล้ว +1

    As always -- this is 🔥🔥🔥🔥🔥!

  • @dv8416
    @dv8416 ปีที่แล้ว +1

    That was a fantastic tutorial!! Thank you!

  • @CharTV0104
    @CharTV0104 ปีที่แล้ว +1

    This video was so helpful. I was able to change the button for my Image Text with EASE! I'm definitely subscribing for more tips.

  • @runads
    @runads ปีที่แล้ว +1

    Helped me fix my problem in Shopify, thanks

  • @darmar8609
    @darmar8609 ปีที่แล้ว +1

    Really appreciated this video!

  • @majaregua2024
    @majaregua2024 ปีที่แล้ว +1

    Great tutorial, thank you!

  • @retrocamerafix
    @retrocamerafix ปีที่แล้ว +1

    Thanks Ed - really useful

  • @matthiashoeschler
    @matthiashoeschler ปีที่แล้ว +1

    This really helped me. Thanks a lot :)

  • @rush8222
    @rush8222 2 ปีที่แล้ว +1

    THANK YOU ED!!!!!

  • @neilarchibald3600
    @neilarchibald3600 ปีที่แล้ว +1

    Great video, helped me out with a few things!

  • @ryaaan0751
    @ryaaan0751 8 หลายเดือนก่อน

    Really helpful video! Thanks for this!

  • @AladdinsGenie-com
    @AladdinsGenie-com ปีที่แล้ว +1

    Ed thank for you videos. You are a good teacher =) how to change, add or remove boder lines or border colors on buttons or for example the searchbar so it becomes more visible. Thanks

  • @NeoNordstom
    @NeoNordstom ปีที่แล้ว

    Bro I love you man

  • @chad.765
    @chad.765 2 ปีที่แล้ว +4

    Thanks Ed, this was really helpful. I've been creating new classes for things trying to target them but this was a great demonstration of how to work backward through nesting to increase specificity without adding anything.
    Suggestion for a future video: help us understand/decipher what the Dawn theme and its derivatives are actually doing with all of the pseudo classes surrounding core elements. For example: button classes have a lot of ::before and ::after styling. It makes it difficult at times to track down the correct thing to modify for a change, and sometimes results can be unexpected. I don't entirely understand what these classes are doing and why they're necessary for things like buttons.

    • @EdCodes
      @EdCodes  2 ปีที่แล้ว +2

      Good question. They're not really necessary IMO... I feel like Dawn went a bit too far with creating lots of options for button styling and now its too complicated.
      ::before and ::after pseudo elements are just a way to generate an extra element using CSS, which is cleaner than actually adding a or something redundant in HTML just for styling purposes.
      In Dawn, they are using ::after to create a fake border, so that they can give you a border opacity setting (with normal css borders you cant change opacity). The ::before is used to add a shadow, and you can also change its opacity, offset and blur.
      You can find all these settings in theme settings > Buttons.

  • @MKitson
    @MKitson ปีที่แล้ว +1

    Great vid, thank you! Do you have any similar videos or guidance on text positioning? For example how to be more specific than just middle, bottom, etc

  • @NoremacWW
    @NoremacWW ปีที่แล้ว +1

    Ed, I have learned so much from your channel! Do you have a tutorial on creating custom product badges/labels or some sort of image overlay on the collection thumbnail images without having to buy a monthly app? I'd like to show customers there's multiple sizes available for some products on some of my items, but the apps out there are not great design and cost too much per month.

  • @o.mohtar-hc4jt
    @o.mohtar-hc4jt 11 หลายเดือนก่อน +2

    What if I can't find the global.css nor base.css. I am using Xtra theme

  • @vdecides
    @vdecides ปีที่แล้ว +1

    Hey Ed, Your tutorials are great! Would you mind help us know how to add clickable image slider and banner with just the image and no buttons in it? Also how do we add responsive image to it? having a separate mobile responsive image for the slider.

  • @levipater3983
    @levipater3983 ปีที่แล้ว +1

    Great vid! Was looking for this. Is it possible to also add a color gradient to the button? I tried to add for example: linear-gradient(136deg, rgba(10, 234, 237, 1) 11%, rgba(250, 13, 253, 1) 84%) to the 'custom.css' but it doesnt seem to work. Is there another option? Would like to apply a color gradient to my buy buttons

  • @Studioruthart
    @Studioruthart ปีที่แล้ว +1

    Thank you for this but my Shopify doesn't have base css? Not sure what to do?

  • @yassinebouhlali6452
    @yassinebouhlali6452 ปีที่แล้ว +1

    Is it possible to do it with a different way. For instance, can you add a new color suggestion in the colors in the theme parameters ? You go to the json config, you add a new box ? But I tried and it failed... don't know why ...

  • @setyourhandel340
    @setyourhandel340 9 หลายเดือนก่อน +1

    I do not know if this question was answered or not..what is the best Shopify theme that's not over loaded with 10 different choices ?? Simple to use , and can be coded without breaking your site.

  • @dalevandenheuvel3927
    @dalevandenheuvel3927 ปีที่แล้ว +1

    Just wondering about the opening soon page and the overlay color, can this also be changed?

  • @extramilemotive
    @extramilemotive ปีที่แล้ว +1

    Hey man, how can i make banner button wider? i have been trying with different width but only the color becomes wider not the actual border and the text stays on the left. will be much appriciated if you could help. Thanks

  • @TJ-TJ
    @TJ-TJ 2 ปีที่แล้ว +1

    Best to use the custom liquid section on pages to change the CSS as it will get overwritten with theme updates

    • @EdCodes
      @EdCodes  2 ปีที่แล้ว +1

      Too easy to lose track of or forget about completely. Especially when you are using different templates, then you would be copy pasting the section a lot, and have multiple copies of it, making it hard to make a change. I prefer to make a separate file and then add that file to the new theme after updating.

  • @gracebreshears5075
    @gracebreshears5075 2 ปีที่แล้ว +1

    When I use both the add to cart and buy now button how could I make the add to cart button solid and the buy now button outline for dawn

  • @eBikeRevolution
    @eBikeRevolution ปีที่แล้ว +1

    Hey. I followed the steps in this tutorial to change the button colour but it looks like it is being overwritten by something else as the css code is crossed out in inspect element. How do i get around this?

  • @alerudu7131
    @alerudu7131 ปีที่แล้ว +1

    Also which one do I do to make my custom font show in every page both desktop and mobile because right now mine only shows on desktop

  • @glitterhaven
    @glitterhaven 2 ปีที่แล้ว +1

    Thank you so much for this - I've been desperately searching for a way to change the font colour on different product templates. 💖 I'd love to be able to hide the Card Headings on the Collection List on Homepage (I think I have found where to change the font colour, but I actually don't want it there at all

    • @EdCodes
      @EdCodes  2 ปีที่แล้ว +1

      You can use display: none; to hide something completely. E.g. .your-card-heading-class { display: none; }

  • @SuperLions7
    @SuperLions7 ปีที่แล้ว +1

    Hello, can you please explain how to do this for the search field?

  • @Lillush22
    @Lillush22 ปีที่แล้ว +1

    Such a good video but my font still not changing its colour for me😅 drives me nuts

  • @alerudu7131
    @alerudu7131 ปีที่แล้ว +1

    Does doing this make my custom font show on both desktop and mobile?

  • @joannahong6262
    @joannahong6262 10 หลายเดือนก่อน +1

    Can I isolate the changes to mobile only?

  • @KayDerr
    @KayDerr 11 หลายเดือนก่อน +1

    Just found you and I really like your video. I have a problem and can not go any further. It will not allow me to add a new assets. Can you explain why?

  • @MichelleGreen-zg7mm
    @MichelleGreen-zg7mm 4 หลายเดือนก่อน

    What can u do if the theme maker used CSS variables and the normal way of adding custom CSS isn't working?

  • @selimhanhimatov3515
    @selimhanhimatov3515 ปีที่แล้ว +1

    how can i change the text in a button ?

  • @trend_ripple
    @trend_ripple 5 ชั่วโมงที่ผ่านมา

    Thanks for the video Ed! My issue now is that I want to ensure my mobile font is bigger than the current one without affecting the desktop view! would this code work? .product__description mobile {font-size:15px !important;}

  • @samantharstone
    @samantharstone ปีที่แล้ว +1

    Thank you for this tutorial! Instead of writing 'green' or a color description, are you able to add a Pantone or Hex # to dial down to an exact color?

    • @EdCodes
      @EdCodes  ปีที่แล้ว +1

      Yeah, you would definitely be using a hex color in a real project. I'm only demonstrating with these standard color names. But as for Pantone codes, no those won't work. You need to find the equivalent hex or RGB.

  • @simply.healthy
    @simply.healthy ปีที่แล้ว +1

    Hi Ed - How does someone contact you? I want a custom block built for my Shopify Dawn theme.

  • @dmitriylazar1941
    @dmitriylazar1941 ปีที่แล้ว +1

    Hi, Ed.
    You would greatly help me if you explain in a few words, how to insert background image in css? Thank you

    • @dmitriylazar1941
      @dmitriylazar1941 ปีที่แล้ว

      I mean not to the whole page, but individually, H1 for example, how do I put image for H1 background using css?

  • @dzoka4947
    @dzoka4947 ปีที่แล้ว +1

    Hey Ed, great video! Have a question tho. How would you change a specific li inside ul without it affecting all other li inside the sam ul element?

    • @EdCodes
      @EdCodes  ปีที่แล้ว

      You can give it it's own class in html maybe? Or if not, then with CSS you can target it with :first-child or :last-child or :nth-child
      developer.mozilla.org/en-US/docs/Web/CSS/:first-child
      developer.mozilla.org/en-US/docs/Web/CSS/:nth-child

    • @dzoka4947
      @dzoka4947 ปีที่แล้ว

      @@EdCodes Hey Ed, thanks for the feedback. What I did is, copied the code for the whole ul and asked ChatGPT to help me, and it did, I got exactly what I wanted.

  • @evie9603
    @evie9603 7 หลายเดือนก่อน

    This video is great!! It helped me change some colours around, but I wanted to change my heading font families so h1 h2 h3 etc would be a different font. I tried to do this by changing family for h4 or h2 for example, but nothing happened! Any advice?

    • @EdCodes
      @EdCodes  6 หลายเดือนก่อน

      Are you changing them to a font that's already being used elsewhere in your theme? Your font picker settings in Shopify actually load in the font files. So you can't just use any font. But if you already selected that font for some text then you might be able to use it in css also. Hard to say without seeing your store and theme. Also make sure you are targeting with enough specificity in your css to overwrite it.

  • @Human_Evolution-
    @Human_Evolution- ปีที่แล้ว +1

    Dawn has a problem with font size on mobile, the headings are way too big. Also, font size matching. We tend to have headings all over the page that are different sizes. It is not ideal.

  • @Whosnikozis
    @Whosnikozis ปีที่แล้ว +1

    bro I still don't understand how to change text colors for separate sections. I've searched the whole web and there's nothing about this

  • @petrasotonova
    @petrasotonova 2 หลายเดือนก่อน

    Awesome, thank You so much! Is it true, that there is no way to customize checkout page? CSS doesn't work, when I try to make changes on this page, but anywhere else yes. Thank You again. Have a great time.

    • @EdCodes
      @EdCodes  2 หลายเดือนก่อน

      Yes, it's true. You need Shopify Plus to customize the checkout page.

    • @petrasotonova
      @petrasotonova 2 หลายเดือนก่อน

      @@EdCodes Thank You for Your reply and for Your work! Great time to You.

  • @manavmuthreja4085
    @manavmuthreja4085 ปีที่แล้ว

    i.. cant thank you enough..............

  • @ralphcalubaquib3275
    @ralphcalubaquib3275 ปีที่แล้ว

    Is it possible to apply RGB colors in text or background?

    • @EdCodes
      @EdCodes  ปีที่แล้ว

      yeah of course - color: rgb(255,255,255);
      www.w3schools.com/css/css_colors_rgb.asp

  • @christalize
    @christalize ปีที่แล้ว +1

    do you know how to put a figma website on shopify

    • @EdCodes
      @EdCodes  ปีที่แล้ว

      Check out a pagebuilder called Replo, it's a lot like Figma - ed.codes/blog/replo-a-shopify-page-builder-for-figma-designers

  • @setyourhandel340
    @setyourhandel340 9 หลายเดือนก่อน +1

    Shopify is nothing more than wordpress, another useless piece of software. Your doing a Good job explaining and making it easier to change things in Shopify. And FASTER..!!!

  • @eileenwang5943
    @eileenwang5943 ปีที่แล้ว

    what an amazing tutorial! Many thanks!