Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How to create decent image thumnails #19

Closed
animaux opened this issue Jul 24, 2014 · 33 comments
Closed

How to create decent image thumnails #19

animaux opened this issue Jul 24, 2014 · 33 comments

Comments

@animaux
Copy link
Contributor

animaux commented Jul 24, 2014

I get this done with quite a bit of hassle. What is the textbook-way to do it? You mention predefined selector styles.

@animaux
Copy link
Contributor Author

animaux commented Jul 24, 2014

Jetzt hätten wir doch noch was klären können … grundsätzlich geht’s nun.

reflection field expresion: <img src='{root}/image/2/40/40/5/{entry/datei/filename}' /> {entry/titel}<br/><em>{entry/datei/filename}</em>

Using this reflection field fork mentioned here. Is there a way to get values for $root or $workspace without resorting to this fork? Would be bad if one had to use absolute URLs, especially when using a development server.

Only slight layout problems:

bildschirmfoto 2014-07-24 um 15 08 28

@nilshoerrmann
Copy link
Contributor

Actually I thought both variables were available already. Hm.
If not, why not ask @andrewminton to send a pull request to the main Reflection field repository?

I'll have a look at the image margin.

@nilshoerrmann
Copy link
Contributor

The styling should be fixed.
If you are using a layout with two lines, an image size of 35 works best.

@animaux
Copy link
Contributor Author

animaux commented Jul 29, 2014

Looks good, cheers!

Not sure where to post this, List view is still borked though (I might as well turn that of, as it is of no great use):

bildschirmfoto 2014-07-29 um 09 47 02

@nilshoerrmann
Copy link
Contributor

Well, that's not exactly an issue of this extension, but of Association Field: it just displays the markup of your Reflection Field.

That can be solved by either changing the output of Association Field (not good in my eyes), by adding styles to Association Field or by adding custom styles with Admin CSS Override.

@animaux
Copy link
Contributor Author

animaux commented Jul 29, 2014

Ok, thanks Nils.

@nilshoerrmann
Copy link
Contributor

Personally, I'd say using a custom CSS override might be the best because the index content really depends on the project's needs. But we should discuss this on the extensions' repo.

@andrewminton
Copy link

Gents, Alex mentions above the potential issue of absolute URL's in the thumbnail views.. Even if we add the Root and Workspace constants as output nodes in the XPath, we'd still have to re-save all of the entries that include the Reflected constant no? i.e. moving servers would make no difference if using constants from Xpath cos the refleciton field makes the changes upon save.. they are not dynamically loaded..

Is it worth considering a JS solution for root and workspace from the Symphony Environment Variables here somehow?

I've sent a PR with date and constants to the integration branch for now anyways.. my forks has hashing of the reflected content in there which I need to strip out so I just patched it in the browser for now.

@nilshoerrmann
Copy link
Contributor

Why not make the Reflection Field evaluate $root and $workspace just in time (= not during saving but while displaying content)?

@animaux
Copy link
Contributor Author

animaux commented Jul 30, 2014

@nilshoerrmann @andrewminton brill! I’d say go for that.

@animaux
Copy link
Contributor Author

animaux commented Jul 30, 2014

(resaving shouldn’t be a problem though using the resave_entries extension)

@andrewminton
Copy link

@nilshoerrmann That's what I was thinking. A bulk resave using resave_entries is also a neat way but wouldn't it be great to not need to worry about that when moving from a Dev to Live environment.. these things are very easily forgotten in the excitement of the switch to live.

@animaux
Copy link
Contributor Author

animaux commented Jul 30, 2014

wouldn't it be great to not need to worry about that when moving from a Dev to Live environment

Absolutely!

@nathanhornby
Copy link
Contributor

+1 I loathe static references (shakes fist at Redactor)

@animaux
Copy link
Contributor Author

animaux commented Aug 13, 2014

Still display issues with the reflection field caption and edit icon:

bildschirmfoto 2014-08-13 um 13 27 04

@nilshoerrmann
Copy link
Contributor

Reintroduced by aed1929.

@animaux
Copy link
Contributor Author

animaux commented Aug 13, 2014

Is the background supposed to be white now, or is there some leftover css fussing this over?

@nilshoerrmann
Copy link
Contributor

Single selects are supposed to be white because search and select share the same area.

@animaux
Copy link
Contributor Author

animaux commented Aug 13, 2014

Ok, great!

@animaux
Copy link
Contributor Author

animaux commented Aug 14, 2014

Ok, I have a no-quite-so-dirty solution for the slightly complicated usecase of optional images … @nilshoerrmann where should we put this for documentations sake? Wiki?

@nilshoerrmann
Copy link
Contributor

What about extending the readme?
https://github.com/hananils/association_ui_selector#custom-captions

@animaux
Copy link
Contributor Author

animaux commented Aug 14, 2014

Ok, but I was thinking of adding an example XSLT Utility. So this could become rather longish.

@nilshoerrmann
Copy link
Contributor

Well, if you think it'll become too long, let's move it to the wiki.
But from my experience, people take a look at the readme, if you're lucky. They don't look any further.

@nathanhornby
Copy link
Contributor

Well, if you think it'll become too long, let's move it to the wiki.
But from my experience, people take a look at the readme, if you're lucky. They don't look any further.

There's a wiki??

@animaux
Copy link
Contributor Author

animaux commented Aug 14, 2014

@nathanhornby not yet :)

@nilshoerrmann
Copy link
Contributor

@nathanhornby
Copy link
Contributor

I completely forgot about that Github feature! Although I was mostly making a joke about me not looking any further than the readme 😊

@nilshoerrmann
Copy link
Contributor

We are Germans. We don't understand jokes. Sorry.

@DavidOliver
Copy link

@nilshoerrmann
Copy link
Contributor

You see.

@andrewminton
Copy link

Hahah! Henning is an awkward genius :).. Serious note.. what's a WIKI?

@nathanhornby
Copy link
Contributor

Haha @DavidOliver @nilshoerrmann

@animaux
Copy link
Contributor Author

animaux commented Aug 14, 2014

Wenn ist das Nunstück git und Slotermeyer?

Ja! Beigerhund! Des oder die Flipperwald gersput!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants