How To Target One Thing in Squarespace with Code // CSS Targeting Tips for Squarespace

Поделиться
HTML-код
  • Опубликовано: 1 дек 2024

Комментарии • 51

  • @InsideTheSquare
    @InsideTheSquare  Год назад +1

    ⚠ IMPORTANT CSS UPDATE ⚠ When logging into Squarespace, if you see the word "Website" at the top of your menu, you are using their new internal navigation!
    To edit the CSS of your Squarespace website, click on the word "Website" and scroll to the bottom of the list of pages. Here you'll see "Website Tools" - click on that option and select "Custom CSS" to open the CSS panel and add your code here. For more information, watch this tutorial: ruclips.net/video/euJqHXs_L1M/видео.html

  • @cinemaric
    @cinemaric 3 года назад +3

    Thank you becca for all that you do. You are very much appreciated!

  • @marie-stellamakoumbou2709
    @marie-stellamakoumbou2709 Год назад

    I rarely comment on RUclips videos, but THANK YOU SO MUCH! I was trying to upload videos with the 9:16, so I watched your video about how to change the video block ratio on SquareSpace, which, worked, but it did so for ALL the videos on the site!

    • @InsideTheSquare
      @InsideTheSquare  Год назад

      Yay! So happy I could help - thanks for letting me know it worked!! 🙌

  • @JeannetteWeinstein
    @JeannetteWeinstein 8 месяцев назад +1

    Hello - thank you for all of your help. Is there a way to put the summary image below the title and description?

    • @InsideTheSquare
      @InsideTheSquare  8 месяцев назад

      Great idea! I don't have a code for that just yet, but I will add it to my tutorial to do list, so stay tuned 🙌

  • @ydillon96
    @ydillon96 5 месяцев назад +1

    Hi, I was curious if you knew of a way to make multiple product variation buttons all different styles. I found a way to use an image as a product variant button, only problem is it uses that image for all the buttons and not just my 1st product variant.

    • @InsideTheSquare
      @InsideTheSquare  5 месяцев назад

      This is a great question! You can target specific variant buttons using nth selectors. This code would give a red background to the second button on the third variant of a product:
      .variant-option:nth-child(3) .sqs-button-element--secondary:nth-of-type(2){
      background: red!important
      }

  • @patriciomartinez9350
    @patriciomartinez9350 3 года назад

    You are a star! Thanks for sharing all this knowledge. The best SS tutorials.

    • @InsideTheSquare
      @InsideTheSquare  3 года назад

      You are so welcome - thanks for the kind words 🥰

  • @browsersydney90
    @browsersydney90 7 месяцев назад

    thank you so much. You've saved me several times already. I was wondering if you are able to add CSS code to one element across your whole site. Eg. Change all image carousels or all people carousels but it won't change it in simple list.

    • @InsideTheSquare
      @InsideTheSquare  7 месяцев назад

      Great question - and yes - it's totally possible! It's all about how you target the thing in your code. You can use the selector class, the block id, or both! I have a video with. more info that can help you figure out the perfect way to write code for your project: insidethesquare.co/squarespace-tutorials/css-targeting-tricks

  • @regenhealth4238
    @regenhealth4238 2 года назад +1

    So helpful and so much appreciated

  • @fitzmauriceworks
    @fitzmauriceworks 2 года назад +1

    Terrific. So well explained and enabling.

  • @n8n565
    @n8n565 2 года назад

    This is sooooooo helpful

  • @ruthhowsamdesign7268
    @ruthhowsamdesign7268 Год назад +1

    Hey Becca!
    Thanks for the great code.
    I'm trying to use this to target about 15 different text/images on one page, same section.
    I'm trying to target multiple block-ids within the same section, but when I add a comma to separate them, it doesn't work, and code only applies to the last block-id I enter.
    For example, here I am trying to target 2 block ID's:
    @media only screen and (min-width: 640px){
    #block-yui_3_17_2_1_1694528858998_6548, #block-0b61a32fa7be91cf579f {
    opacity: 0;
    transition: opacity 1s
    }
    #block-yui_3_17_2_1_1694528858998_6548, #block-0b61a32fa7be91cf579f:hover {
    opacity: 1;
    transition: opacity 1s
    }
    }
    But the effect only works on the last block-id (in this case, the one ending in 79f).
    Ideally, I'd like to target 15 text/images, just separated by a comma - is this possible? I've been trying for about a week to be able to do this but really struggling!
    THANKS!!

    • @InsideTheSquare
      @InsideTheSquare  Год назад

      You were totally on the right track separating the selectors with a comma! The tricky part is the hover - you have to add that state to every selector too, like this: #block-yui_3_17_2_1_1694528858998_6548:hover, #block-0b61a32fa7be91cf579f:hover, #block-yui-1234567:hover, #block-yui-89012345:hover
      Hope that helps and best of luck with your project!

  • @AmyFeiman
    @AmyFeiman 6 месяцев назад

    I have my color palette set, but I'd like to change a section background color - outside of my color palette - I have located the section ID but when I code {background-color: #hexcolor} it doesn't change the color. What am I doing wrong?

    • @InsideTheSquare
      @InsideTheSquare  6 месяцев назад

      Page sections have different layers to them so you need to target the specific selector class within the page sections that has the color. Try using [data-section-id] .page-section .section-background {background-color: #hex!important}
      You can also try using .page-section .section-border
      Make sure you add !important because you are overwriting the original code. Hope that helps and best of luck with your project!

  • @elijahaaron
    @elijahaaron 2 года назад +1

    What about changing atributes to entire blocks on the whole site (like changing how to the add to cart loooks or giving all code injection and image blocks no padding)

    • @InsideTheSquare
      @InsideTheSquare  2 года назад

      Hey Elijah! You can customize just about anything in Squarespace with CSS if you know the selector name. 👍👍

    • @elijahaaron
      @elijahaaron 2 года назад

      @@InsideTheSquare but how do I find the selector name? I bought your css book. It’s awesome 😎

  • @zahraarcher
    @zahraarcher Год назад

    Thanks Becca. I've tried and tried and failed with this: I want to hover over text and change the section background colour. I can only manage to get the text background to change colour on hover.

    • @InsideTheSquare
      @InsideTheSquare  Год назад

      Gotcha @zahrarcher - thanks for the details - helps me troubleshoot 🙌 CSS changes the style of an object - but it can’t change other things that aren’t related… so if you hover over one thing, you can change stuff about that one thing, but you can’t change anything else that isn’t connected. There are some workarounds toucan do when you add other code languages like JavaScript; I’d recommend posting in the forums to see if anyone has advice. Hope that info helps and best of luck!

  • @BlueMAnimations
    @BlueMAnimations Год назад

    Hi! I have a question... How do you change the Language text to uppercase?

    • @InsideTheSquare
      @InsideTheSquare  Год назад

      Interesting question Blue! We can change almost all text to uppercase with the property:value of "text-transform:uppercase" but we need to make sure we are assigning those properties and values to the right selector. So - what is the "language" that you want to change? is it a link in your main navigation or the Weglot translation link? Let me know and I'll help you make it happen :)

  • @gabriellewong211
    @gabriellewong211 6 месяцев назад

    what extension is this on chrome?

    • @InsideTheSquare
      @InsideTheSquare  6 месяцев назад

      Squarespace id finder. Not affiliated; just a fan. Here is a quick link for ya: insidethesquare.co/chromeext

  • @sarahnikas8634
    @sarahnikas8634 8 месяцев назад

    hello! I just did this and it worked! But then all of a sudden, my code is showing up at the top of the actual page! I even tried deleting the code all together and it's still there! Help!

    • @InsideTheSquare
      @InsideTheSquare  8 месяцев назад

      When you add CSS code to code injection, you need to label it as CSS code so the computer browsers knows what to do. Make sure your code is in style brackets like this: your code
      Check out this tutorial for more info: insidethesquare.co/singlepage

  • @KatharineForgan
    @KatharineForgan 6 месяцев назад

    Hi, super useful but struggling to integrate with another of your tutorials: I made 2 columns for simple lists on the mobile view by adding your code to the page header code injection, but I only want it to target one data section of the page. Does this targeting not work in the page header code injection? See my attempt to integrate, where am I going wrong as this code still affects the whole page! Thank you so much.
    [data-section-id=”166203b538e09a34f744ffe34”]
    @media only screen and (max-width: 640px){.user-items-list-simple:not([data-num-columns="1"]) {grid-template-columns: repeat(2,1fr); grid-gap: 10px!important} .list-item-content__title{font-size: 1rem!important} .list-item{padding: .5rem!important}}

    • @InsideTheSquare
      @InsideTheSquare  6 месяцев назад +1

      You need to add the data section id before the selectors, like this:
      @media only screen and (max-width: 640px){[data-section-id=”166203b538e09a34f744ffe34”] .user-items-list-simple:not([data-num-columns="1"]) {grid-template-columns: repeat(2,1fr); grid-gap: 10px!important} [data-section-id=”166203b538e09a34f744ffe34”].list-item-content__title{font-size: 1rem!important} [data-section-id=”166203b538e09a34f744ffe34”] .list-item{padding: .5rem!important}}
      To learn more, check out my free guide to basic CSS at insidethesquare.co/learn

    • @KatharineForgan
      @KatharineForgan 6 месяцев назад

      @@InsideTheSquare thank you kindly for this! It didn't work at first, but I then re-worded the Data Section bit to: section[data-section-id="662022bd442ea802ee8e00b4"] as it pulled from the chrome plugin and it worked perfectly! Thank you again!

  • @and.coaching
    @and.coaching 3 года назад

    Appreciate all the content support- however, when I put in the code (and the collection ID) it doesn't do anything? Can you help I'm on 7.1

    • @InsideTheSquare
      @InsideTheSquare  3 года назад

      Hey RLC Global! You might not be targeting the right selector, property, or value - it's hard to know without seeing the code in action! 🤔 Feel free to submit a code help request with more info at insidethesquare.co/code-help

  • @MARVELousBros
    @MARVELousBros 2 года назад

    HELP! I HAVE A GRIDDED PORTFOLIO PAGE AND WHEN U HOVER OVER A THING IN THE GRID IT SAYS THE NAME OF THE PAGE IT TAKES YOU TO OVER IT HOW DO I CHANGE THE FONT OF THAT!?!?

    • @InsideTheSquare
      @InsideTheSquare  2 года назад

      I’m not sure why it would do that instead, but I’d be happy to help! Feel free to submit a code help request with more info here: insidethesquare.co/code-help

    • @ElishaZepeda
      @ElishaZepeda Год назад

      I also can't find how to change the font on hover. It doesn't seem like it's connected to any specific header or paragraph. There is also no padding, and the font hits the edge of the image. Did you figure this out?

  • @anawile3152
    @anawile3152 3 года назад

    Not kidding, my first thought was Is it Tuesday? 😁

    • @InsideTheSquare
      @InsideTheSquare  3 года назад

      Haha - don't worry - I have another fun tutorial for tomorrow too 😉

  • @ElishaZepeda
    @ElishaZepeda Год назад

    This is honestly where Squarespace loses me to Wix. They make it so difficult to simple change a specific single item on a page - whereas Wix makes it so that you simply click the exact item you want to change.
    Want to change the color of a button? On Wix, click that button, all your options are there. Easy!
    Well on Squarespace, you have to:
    save your site -> edit site styles in a different window -> choose color (want to change font? different window! start again!) -> scroll down to the specific button (is this a primary, secondary, etc.) -> etc.
    Or you can learn how to custom code. Which defeats the purpose of "easily" building your site.
    If it weren't for helpful accounts like these I'd be completely lost.

    • @InsideTheSquare
      @InsideTheSquare  Год назад +1

      Thanks for the thoughtful feedback, and I’m glad you like my work! There's no "perfect" platform, and each designer has their preference.

    • @jgalvan09
      @jgalvan09 Год назад

      I mean it's understandable if you don't know how to code but this is super easy stuff if you're 33 like me and you ever had MySpace, then you know CSS very well because it was the very first site to let you customize your entire profile page, essentially known as " changing HTML files content using CSS - cascading style sheets

  • @fezenstein
    @fezenstein Год назад

    Hello - I'm targeting specific section on page and am able to do that by searching for data-section-id - and finding the long string of numbers. that's fine once. I want this section to be on many pages, so I save the section - and add it to a new page, but then finding the id again and again makes for cumbersome code? is there a way of saying this section has an id of "sticky-categories" and then everytime I place that section into a page - the styling that is associated with "sticky-categories" gets applied?
    doing this: [data-section-id=”63d2d9da32af660a9bb515e7”],
    [data-section-id=”63d3f99f03e4472872bcea8a”],
    [data-section-id=”63d3f9d3e68141630f2d2375”],
    [data-section-id=”63d3fa0096f1a24a26e4a399”],
    [data-section-id=”63d3fa337d11266dadde5407”],
    [data-section-id=”63d3fa5bfc703f102cee7de3”],
    [data-section-id=”63d3fa9ff18e2f67b26f99ed”]
    for every page of a 30-40page website isn't a good solution? any ideas how to streamline this?

    • @InsideTheSquare
      @InsideTheSquare  Год назад

      Great Question! Adding code to your site-wide CSS file under design > custom CSS will put your code on every page. But there are two ways to add code to a single page - check out this tutorial for more help: insidethesquare.co/singlepage
      You can also use a unique block ID to target a specific thing on your site; check out this tutorial for more info: ruclips.net/video/h8qfZdaATbU/видео.html
      I use this free Chrome extension to grab that info; not affiliated - just a fan! chrome.google.com/webstore/detail/squarespace-id-finder/igjamfnifnkmecjidfbdipieoaeghcff
      Hope that helps! 💙

  • @Racewun
    @Racewun 2 года назад

    Hi! Do you have an email I could contact you at? Want to ask if you know whether or not it’s possible to do this thing I want to do in squarespace.

    • @InsideTheSquare
      @InsideTheSquare  2 года назад +1

      HI there - absolutely! You can reach my on my website at insidethesquare.co/contact

    • @Racewun
      @Racewun 2 года назад

      @@InsideTheSquare Done!