Hello everyone,
I got an issue with the panel in Kirby 3.4.0, on local development (with Kirby Webpack). I want to display all project
pages, which are children of a projects
page, from my site.yml
.
When I try to use a pages
section with a parent parameter (parent: site.find("projects")
), the projects pages starts to display correctly but the panel starts to go crazy and refresh the page endlessly.
My content structure looks like this:
/1_home
/2_contact
/projects
/1_project-a
/2_project-b
/3_project-c
My pages section looks like this in site.yml
:
sections:
projects:
headline: "Projects"
type: pages
status: published
parent: site.find("projects")
When I remove the parent
parameter, the infinite refresh looping stops (but pages are not displayed anymore obviously…).
Do you have an idea of what could trigger the page to refresh?
EDIT : Seems the issue is relating to files in the panel (the page is looping when being on a tab or page using or displaying a file) . Maybe the media generation is causing a infinite looping. But I don’t know why…
Could you please post the complete site.yml blueprint?
Also, is this a standard or multi-language installation? What are steps to reproduce the issue?
This is a standard installation, no multi-languages.
Here is the all site.yml
file:
title: Site
options:
changeTitle: false
tabs:
projects:
label: Pages
icon: text
columns:
- width: 1/2
sections:
pages:
headline: "Pages"
type: pages
create: project
templates:
- home
- contact
- projects
sortBy: title desc
- width: 1/2
sections:
projects:
headline: "Projects"
type: pages
create: project
parent: site.find('projects')
options:
label: Options
icon: cog
columns:
- width: 1/2
fields:
description:
label: "Description"
type: text
maxlength: 200
email:
label: "Email"
type: email
linkedin:
label: "LinkedIn"
type: text
before: "linkedin.com/"
icon: linkedin
To be honest, I don’t think this is related to the blueprint, because I use something similar in another project and it works.
It is weirdly related to files/images. Each time I go to the Panel and there is a page or a field with an image, the Panel starts looping forever. It seems like the API is regenerating the preview image of the file again and again. I tried replacing the image, deleting the media folder… without success.
Look at it:
If I remove the image from the image field in the Project page, the looping issue disappear.
Hm, but what your are showing me is not based on site.yml, but the projects page, so based on projects.yml
not site.yml
.
projects.yml
:
title: Projects
icon: 🖼
options:
changeSlug: false
changeStatus: false
changeTemplate: false
changeTitle: false
duplicate: false
sections:
projects:
headline: "Projects"
type: pages
create: project
Why is this called pages.yml, not projects.yml?
Just edited, it is projects.yml
, not pages.yml
, sorry!
Ok, since I’ve never experienced this and can’t reproduce with your blueprints, I wonder if it’s an issue with the Webpack starterkit refreshing the page. Please test if you also have this issue in a standard Starterkit.
I use the Kirby Webpack starter kit since 3 years, and for 2 current projects with Kirby 3.4.0, never experienced something like this. I’ll try a “fresh install” of my project and see…
Ok the issue was coming from a new version of BrowserSync…
So for other people using Kirby Webpack after updating their dependencies, if you got a looping issue, roll back to browser-sync@2.26.7
.
Thanks @pixelijn for your help!