views – What is correct way to make custom slider module? slide update problems

That code is wrong, as the variables key should not give default values that dynamically change. hook_theme() is not invoked every time a theme hook is necessary, but only then the theme hook registry needs to be re-built. The code invoking hook_theme() is the following one, in Registry::build().

  if ($cached = $this->cache->get('theme_registry:build:modules')) {
    $cache = $cached->data;
  else {
    foreach ($this->moduleHandler->getImplementations('theme') as $module) {
      $this->processExtension($cache, $module, 'module', $module, $this->getPath($module));

    // Only cache this registry if all modules are loaded.
    if ($this->moduleHandler->isLoaded()) {
      $this->cache->set("theme_registry:build:modules", $cache, Cache::PERMANENT, (

That explains why clearing the cache the code works.

Code that would work is similar to the following one.

function my_module_theme() {
  return array('slider' => array(
    'variables' => array(
      'slides' => NULL,

class FlexSlider extends BlockBase {
   * {@inheritdoc}
  public function build() {
    return array(
      '#theme' => 'slider',
      '#slides' => my_module_get_slides(),
      '#attached' => array(
        'library' => array(

Depending on what returned from my_module_get_slides, build() could also need to set cache keys, cache contexts, or cache tags to make the output be cached, and invalidate the cache when necessary. See Render API overview for more details on how those values are used for rendered elements.

Woocommerce – different product options in each slide

I'm trying to find out how this result can best be achieved:

A slider where each slide contains a different set of woocommerce products

The "series", as I called it above, can be a real Woocommerce variant, but also all different individual products, if the result looks like this and as soon as the button is added to the shopping cart, the displayed product is added

Is there a premium plugin to do this? or maybe a combination of plugins?
Lately, plugins have completely eliminated the possibility of pre-sale questions, so I haven't had a chance to ask the Revolution Slider team, but it seems that this cannot be achieved.
So far, I would best use Slide Anything, with each slide containing a shortcode for displaying certain products in the form of radio buttons. If there is any plugin for displaying products in this way.

g suite – Extract slide titles from the presentation of Google slides to create a table of contents

I need to extract all of the slide titles from a 100 slide presentation to create a table of contents for a Google document. All slides follow a strict template so that the titles are more or less uniform during the presentation.

I'm trying to do this with the Google Slides API – where I can get a JSON representation of the slide document:[presentation id]

But the json appears to be more of a collection of shapes and text fields, and it doesn't seem trivial to just extract the title text field and its contents.

Does anyone have a way to automatically create a table of contents or an app script or a Google Slides API?

Thanks in advance.

magento2 – Magento 2.3 How do I add a modal slide for related products to the custom page in the administration area of ​​ui_form?

I have created a button in ui_form for custom page and I want that Modal film that appears when I click the button to add related products but I don't know how to do it

I try to repeat the logic of it

Enter the image description here
Enter the image description here

Now I've added a button, but I can't design it to show a modal slide with products when clicked

Enter the image description here

Please tell me how I can do that. I really need help, thanks

Carousel – How to create a plain text slide in the bootstrap

  margin-top: 1%;
  font-family: 'Source Sans Pro', sans-serif;
  font-size: 20px;
  color: #f8f8f8;
  transition: color .26s ease-in-out;
  margin-top: 2%;
  font-family: 'Source Sans Pro', sans-serif;
  font-size: 15px;
  color: #f8f8f8;
  transition: color .26s ease-in-out;
  text-align: justify;