Coder Social home page Coder Social logo

grav-plugin-snipcart's People

Contributors

bredmor avatar couellet avatar flaviocopes avatar mahagr avatar rhukster avatar ryanmpierson avatar salgua avatar sottwell avatar w00fz avatar wingertjp avatar yourselfavent avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

grav-plugin-snipcart's Issues

Product Variation

In your example site you have t-shirts with and add to cart button.

T-shirts tend to come in multiple sizes. How would this be handled with the plugin?

Subscription Item Template does not match Snipcart API

Judging from the commit dates on the Repo, I don't know if this plugin is still actively developed at all, but the snipcart requirements for defining subscription plans has changed.

https://docs.snipcart.com/configuration/recurring-and-subscription-plans-definition

Instead of using 'data-plan-name', 'data-plan-id', etc, Snipcart now expects subscriptions to be defined the same as items - just with 'data-item-payment-interval' and 2 other optional attributes defined.

Multi Language Buttons

Hi! I was thinking to improve the multi language grav to this plugins.

Something like adding the file to the root plugin:
languages.yaml

Then inside this files define all the labels can be modifyed by the language site. For example:

es:
  PLUGIN_SNIPCART:
    CARD: Carrito
    ADD_TO_CARD: 'Añadir al carrito'
    DETAIL: 'Detalle'

ca:
  PLUGIN_SNIPCART:
    CARD: Cistell
    ADD_TO_CARD: 'Afegir al cistell'
    DETAIL: 'Detalls'

Then into :
snipcart_detail_item.html

Add the template for the use the Language traductor tag:
{{ "PLUGIN_SNIPCART.ADD_TO_CARD"|t|e }}

in case of the old "Add" static label.

Any ideas or working progress were welcome!

Best regards,

number of decimal places

Hello,
I want to show my prices with 2 decimal places after the commata ex: 9,60 €
But if the last decimal is a zero it's cut off and shows: 9,6 €
Where do I need to change it to show both decimals even if it is a 0?
Thanks
Oliver

Order custom fields

Hello,

how can I add custom order fields.
In the docs I found this example:
<script id="snipcart" data-api-key="{YOUR_API_KEY}" data-cart-custom1-name="Comments" data-cart-custom2-name="Rating on 10" data-cart-custom2-options="1|2|3|4|5|6|7|8|9|10" data-cart-custom3-name="Do you accept terms?" data-cart-custom3-options="true|false" data-cart-custom3-required="true" src="https://cdn.snipcart.com/scripts/snipcart.js" type="text/javascript"> </script>

But it doesn't add the new fields. Just a new empty tab (that it skips).

thank you

Disabling "Use built-in CSS"

If I disable "Use built-in CSS", how do I specify the CSS file to use without hacking the plugin?

If I hack the plugin/css, they get overwritten when plugin is updated.

Maybe a feature request to have a field in the plugin settings to add /path/to/custom.css

cannot recognize my URL

Does this plugin automatically add the JS file to my grav site when i download it? If i am correct all i have to do is sign up for snipcart and add the "test" API key to the snipcart.YAML file. I have done this and snipcart still will not recognize the JS file on my site. any help?

Category display on iPad

As per my initial Grav forum post, using the Shop Site Skeleton, or probably more specifically, the Snipcart Plugin, items do not display correctly when using an iPad (has worked fine on all other devices tested).

The issue, as seen in the screenshot below, is with the wrapping on nth-child in the CSS. I believe the troublesome lines in css/snipcart.css are:

@media only all and (min-width: 60em) and (max-width: 74.938em) {
.snipcart-products .snipcart-item.block {
width: 33%;
clear: none; }
.snipcart-products .snipcart-item.block:nth-child(3n+1) {
clear: left; } }

I have changed the value of nth-child with varying results, but have not found a solution that works.

Any assistance in determining a solution much appreciated.

screen shot 2015-11-23 at 10 53 02

Filter products?

Hello,
Your plugin just works great!!!
I would just need a little help with a filter-function:
I'm working on a wineshop where I have 4 major categories "Red", "white", "rosé" & "champagne"...
On my website I also have a page about the different wineyards, and now I would like to link the wineyards to their respective wines in the shop but the wines are spreaded in all categories. Is there any way to tag a wine by putting in the snipcart_detail.md something like
taxonomy:
tag: [wine, red wine]
wineyard: oliver
And then set a link on the wineyard-page to a shop-page that shows me all the products of this wineyard?
For ex. a link that would look like:
test.com/shop/tags:oliver
Could you help me please?
Thanks,
Oliver

snipcart_detail_item.html.twig

In the /partial/snipcart_detail_item.html.twig, lines 10 where it shows

{{ snipcart_image.cropResize(400,400).html(page.header.title,'snipcart-thumb-image')|raw }}

single quotes needs to be added between

'page.header.title'

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.