One one site, I have more than 20 content types, which makes the preview feature somewhat cumbersome. I make a change at the top of the page, then scroll all the way down, click "preview", and scroll back up to see the preview at the top of the content types (this happens a lot during development).

Is it possible to move the preview results below the list of content types, so it is closer to the "preview" button? It would be awesome if it could even be outside the fieldset (perhaps in it's own "preview results" fieldset), so I can expand the preview fieldset, choose my content type, collapse the preview fieldset, and easily go back and forth between tweaking my output and clicking preview (all without scrolling).

What do you think?

CommentFileSizeAuthor
#6 custom_formatters.admin.inc.patch1.35 KBjoelstein
Support from Acquia helps fund testing for Drupal Acquia logo

Comments

buzzman’s picture

Is there a test URL you can post so we can see this effect firsthand?

joelstein’s picture

I don't have to which I can give you access. But it's easy to test. Just create about 20 content types (can Devel Generate do this?), and then you'll see what I'm talking about.

Deciphered’s picture

Title: Preview is cumbersome with lots of content types » Lots of content types cumbersome in Devel Generate.
Project: Custom Formatters » Devel
Version: 6.x-1.5-beta1 » 6.x-1.x-dev
Component: User interface » devel_generate

Hi joelstein,

The list of content types is directly supplied by Devel Generate, which means that it is also cumbersome in Devel Generate. While I agree it would be possible to improve the UI, I would prefer it done in Devel Generate so I don't need to replicate existing code.

Moving the issue to Devel Generate for the moment.

Cheers,
Deciphered.

moshe weitzman’s picture

Status: Active » Closed (fixed)

devel_generate does not create content types.

Deciphered’s picture

Status: Closed (fixed) » Active

Talking about the display of Content Types on the Devel Generate screen, as in when there's tons of them the form is massive.

joelstein’s picture

Project: Devel » Custom Formatters
Component: devel_generate » User interface
FileSize
1.35 KB

This doesn't have to do with Devel Generate, but how Custom Formatters displays the preview results. Attached is a patch which places the preview results in it's own "Preview results" fieldset beneath the "Preview" fieldset containing the list of content types. This way, I can collapse the list of content types, and I can easily tweak and preview without any scrolling.

Deciphered’s picture

Having another think about this issue, and you are partially right, this isn't entirely related to Devel Generate as Devel Generate needs to show all as you can select multiple content types, although a multi-selectbox would work. While your approach does also work, I believe that the better choice would be to have the content types in a selectbox, will look into doing this as soon as I have some time.

Cheers,
Deciphered.

Deciphered’s picture

Status: Active » Reviewed & tested by the community

Just had a quick look, and it's a ridiculously simple change:

Change line #232 of custom_formatters.admin.inc from:

        '#type' => 'radios',

To:

        '#type' => 'select',

This will be committed ASAP.

Cheers,
Deciphered.

Deciphered’s picture

Status: Reviewed & tested by the community » Fixed

Committed to DRUPAL-6--1.

joelstein’s picture

Ah, perfect solution. Thanks very much!

Status: Fixed » Closed (fixed)

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