Skip to content

Instantly share code, notes, and snippets.

@dpw1
dpw1 / theme.css
Created May 3, 2022 01:45
Hide price for sold out products on Shopify's Debut Theme
.list-view-item .price--sold-out .price__regular, .list-view-item .price--sold-out .price__sale, .list-view-item .price--sold-out .price__unit, .grid-view-item--sold-out .price--sold-out .price__regular, .grid-view-item--sold-out .price--sold-out .price__sale, .grid-view-item--sold-out .price--sold-out .price__unit{ display: none !important; }
@dpw1
dpw1 / theme.css
Created May 3, 2022 01:46
Hide price for sold out products on Shopify's Debut Theme
.template-product .price--sold-out .price__regular, .template-product .price--sold-out .price__sale, .template-product .price--sold-out .price__unit{ display: none !important; }
@dpw1
dpw1 / base.css
Last active March 6, 2024 21:22
Custom sales badge Dawn theme
/* ## Collection page and sections (change badges color/font size)
https://ezfycode.com/blog/dawn-theme-how-to-customize-badges-color-and-size
================================== */
.card .badge[class*="accent"],
.card .badge[class*="inverse"],
.product .badge[class*="sale"],
.product .badge[class*="sold"] {
border-color: transparent !important;
@dpw1
dpw1 / header.liquid
Last active November 25, 2022 12:44
Dawn sticky header
{% comment %}
____ _ _ _ _ _
/ ___| | |_ (_) ___ | | __ _ _ | |__ ___ __ _ __| | ___ _ __
\___ \ | __| | | / __| | |/ / | | | | | '_ \ / _ \ / _` | / _` | / _ \ | '__|
___) | | |_ | | | (__ | < | |_| | | | | | | __/ | (_| | | (_| | | __/ | |
|____/ \__| |_| \___| |_|\_\ \__, | |_| |_| \___| \__,_| \__,_| \___| |_|
|___/
## Custom Dawn Sticky header by ezfycode.com
{% endcomment %}
@dpw1
dpw1 / ezfy-collection-filter.liquid
Last active March 6, 2024 03:00
How to remove options from the collection filter
<script>
const REMOVE = `manual, best-selling`;
window.ezfyCollectionFilter = window.ezfyCollectionFilter || {};
ezfyCollectionFilter = (function () {
function _isCartPage() {
@dpw1
dpw1 / ezfy-hide-sold-out.liquid
Created October 24, 2022 12:23
ezfycode.com/blog/how-to-hide-out-of-stock-products
<style>
[id] .collection .grid__item--is-sold-out{
display: none;
}
.collection-page--ezfy .loading-overlay{
display: none !important;
}
</style>
<script>
@dpw1
dpw1 / header.liquid
Last active September 2, 2023 01:55
Menu word on mobile
<div class="menu__hamburguer--container" >
<span>
{% render 'icon-hamburger' %}
{% render 'icon-close' %}
</span>
<span class="menu__hamburguer--text">Menu</span>
</div>
<style>
.menu__hamburguer--container{
position: relative;
@dpw1
dpw1 / ezfy-header-search.liquid
Last active March 7, 2023 18:48
EZFY Search
<div class=" EzfySearch EzfySearch--{{ search_type }} search-modal__content{% if settings.inputs_shadow_vertical_offset != 0 and settings.inputs_shadow_vertical_offset < 0 %} search-modal__content-top{% else %} search-modal__content-bottom{% endif %}" tabindex="-1">
{%- if settings.predictive_search_enabled -%}
<predictive-search class="search-modal__form" data-loading-text="{{ 'accessibility.loading' | t }}">
{%- else -%}
<search-form class="search-modal__form">
{%- endif -%}
<form action="{{ routes.search_url }}" method="get" role="search" class="search search-modal__form">
<div class="field">
<input class="search__input field__input"
@dpw1
dpw1 / ezfy-custom-fonts.liquid
Created December 6, 2022 21:19
How to add custom fonts to any Shopify theme
{% if section.settings.enable %}
<style data-custom-fonts>
{% assign items = section.blocks | reverse %}
{% for block in items %}
{% assign name = block.settings.name %}
{% assign url = block.settings.custom_font_url %}
@dpw1
dpw1 / card-product.liquid
Last active March 4, 2024 17:28
Choose which image to show on hover (instead of the second one)
{% assign second_image_number = 3 %}
{% assign image_to_show = second_image_number | minus:1 %}
{% assign ezfy_image_on_hover = card_product.media[image_to_show] %}
<img
srcset="
{%- if ezfy_image_on_hover.width >= 165 -%}{{ ezfy_image_on_hover | image_url: width: 165 }} 165w,{%- endif -%}