I am using the new Fotorama script 4.4.9 and I am new to use API.
I am trying to add custom navigation buttons to the slideshow (stop, pause, previous and next) but I dont know how to implement it using API.
I have been looking at the official page http://fotorama.io/customize/api/
but I cannot get it to work...
Can someone please provide a sample of API custom navigation buttons on the new Fotorama 4?
Thank you
Hi see this answer (https://stackoverflow.com/a/22564811) there i add a customs buttons next and back there is a example how to use the API
Related
I have encountered a situation where I need to display a Dropdown and want the options to dynamically fetch from an API and load on clicking the caret (maybe show a loader by the time the API response comes through). The experience I am looking for is something in the following lines -
Loading (fetching options from API)
Display options after successful response
The documentation didn't give any API surface through which this can be possible.
Is it possible to achieve this with the current APIs that are in place for this control component?
Good point to start is to use BasePicker Component from Pickers.
import { BasePicker } from 'office-ui-fabric-react/lib/Pickers'
Inside BasePicker you have a methods which you can use to make a "lazy" behavior. For example, when you click on component then make a call to API and populate items list.
What is inside BasePicker take a look here or from official documentation.
Codepen example
If anyone can please help me with how to retrieve the navigation menu with REST and Graphql API.
If no API is available, then how can I write a custom Navigation API?
We need to get the below data with API. see screenshot
Use this in query. it worked for me. Remember to replace "main-menu" with the header code of your site.
{
menu(handle:"main-menu"){
items{
id
tags
title
}
}
}
currently, there is no API endpoint that would allow you to access the navigation. However, seeing that the navigation in your screenshot mainly contains collections, probably it would be a good starting point for you to read those? This can actually be done via this call:
GET /admin/api/2020-01/collection_listings.json
You can find more info here:
https://shopify.dev/docs/admin-api/rest/reference/sales-channels/collectionlisting#index-2020-01
Hope this helps,
Roman
I am creating custom sales page in Shopify and add to cart button using "Buy button" code. I have also used Facebook pixel but they are not working for this buy button. Please let me know how to make facebook pixel work with this buy button
Thanks
You can do this two way...
1st is just make a java script function and on the onsubmit event add the fbq('track','AddToCart'); code inside it.
function submitbuybutton(){ fbq('track','AddToCart');}
2nd you can make a form action and write down the facebook pixel fire complete code inside it with fbq('track','AddToCart');
I am using the custom app PortfolioDrillDownAPP on my Rally dashboard (https://github.com/RallyCommunity/PortfolioDrilldownApp/blob/master/deploy/App-uncompressed.html)
I only saw displaycolor under gridFieldBlackList in the code and removed it from there to get the column to be select-able in the app.
Is there a way to get the displaycolor field to be editable as well from the app?
Thanks
I am developing a shopify app.
Is it possible to add a new link to the main menu via the shopify API?
Thanks
If you log in to your partner account and then create an App you can edit the created App and you will see all the resources at your disposal where you can add a new link.
If you notice also, using the API you can pull and rewrite any asset in a shop to contain a new link. This is discouraged as bad practice. Instead, inject a script tag that does the dirty work.
Soon as I know the API itself cannot change something inside the theme files... some APPs ask you to apply some code manually in the theme, with proper instructions... maybe this code could add the new menu or dynamically interact to get it.