This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# This code can be used to decode the session token coming from the | |
# Customer UI extension: https://shopify.dev/docs/api/customer-account-ui-extensions/2024-10/apis/session-token | |
require 'jwt' | |
require 'json' | |
# Replace with your app's client secret from the Partner Dashboard | |
SHOPIFY_CLIENT_SECRET = "XXX" | |
# Token present in the Authorization header of the request |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function applyCSS() { | |
const wishlistButtons = document.querySelectorAll('ooo-wl-product-card-button'); | |
const cssStyles = ` | |
svg { | |
fill: var(--ooo-wl-product-card-button-icon-color, #000); | |
} | |
`; | |
if (wishlistButtons) { | |
// Create style element |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class BulkOperationMutation < ApplicationService | |
STAGE_UPLOAD_MUTATION = <<~'QUERY' | |
mutation($input: [StagedUploadInput!]!) { | |
stagedUploadsCreate(input: $input) { | |
stagedTargets { | |
url | |
resourceUrl | |
parameters { | |
name | |
value |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
"apps": { | |
"wishlist": { | |
"empty": { | |
"title": "Empty wishlist", | |
"description": "You have no products in your wishlist", | |
"link": "Start shopping" | |
}, | |
"share": { | |
"title_without_name": "Shared wishlist", |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// This snippet hides the add to cart and selector from the wishlist page | |
document.addEventListener('DOMContentLoaded', () => { | |
const callback = () => { | |
Array.from(document.querySelectorAll('ooo-wl-select-option')).forEach((item) => item.style.display = 'none'); | |
Array.from(document.querySelectorAll('ooo-wl-button-add-to-cart')).forEach((item) => item.style.display = 'none'); | |
} | |
const observer = new MutationObserver(callback); | |
observer.observe(document.documentElement, { attributes: true, childList: true }); | |
}); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import argparse # Library for parsing command-line arguments | |
import requests | |
import json | |
import logging # Library for logging messages | |
# Parsing command-line arguments | |
parser = argparse.ArgumentParser(description='Remove all variants from a given instance') | |
parser.add_argument('--instance', type=str, help='SubDomain of your QuablePIM', required=True) | |
parser.add_argument('--token', type=str, help='Access Token with full permissions', required=True) | |
args = parser.parse_args() |
NewerOlder