Comments

pol’s picture

Status: Active » Fixed

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.

loparr’s picture

Version: » 7.x-1.x-dev
Status: Closed (fixed) » Active

Hello,
Where can the settings for width and height be found?
Thank you

fluxsauce’s picture

Ah, this was completed and closed, then rolled back due to some destructive changes. There's an active issue requesting this and other features - #1867734: Could we get the attributes so that we could change them to our needs - but this is separate enough to keep it open.

operinko’s picture

Height and width have been re-added as Views configurables.

operinko’s picture

Status: Active » Needs review
xaqrox’s picture

I tried out these new settings and found that my view disappeared when I put "500px" for the height. There's no indication of what if any units to use in these new options. So, here's a patch based on the latest dev that gives the option of choosing px or % for width and height.

xaqrox’s picture

Sorry, the last patch had an error, try this one.

operinko’s picture

Did you test your own patch?
Based on my experiments with the TimelineJS library, when using any unit for the height, timeline won't render.
This is due to it expecting an arbitrary number as the parameter, to be used as pixels.

Height, however, seems to accept px and % correctly.

xaqrox’s picture

I tried both "units" for both dimensions. I use scare quotes there because there is actually no unit used when you choose "px", as per your comment above. In other words, when you enter "500" for the value and "px" for the units, the javascript gets "500", whereas if you choose "%" the javascript gets "500%". See lines 9 and 10 of the patch for that logic. I confirmed that the markup was getting the right values in the style attribute, though the timeline ended up with a computed height of 0 when I used % for height, since the parent element had no height set in my theme. Did the patch work for you?

EDIT: I suppose to be thorough I should test the height with % in a theme that DOES put a set height on div.view-content...

operinko’s picture

The patch does seem to be working, I'll commit it at some point today.

operinko’s picture

Status: Needs review » Fixed

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.