Single Form Widget on CSS Grid Layout

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
6 messages Options
Reply | Threaded
Open this post in threaded view
|

Single Form Widget on CSS Grid Layout

James Yong-2
Hi all,

Planning to add a new form widget type i.e. single_css-grid-layout.
This new type allows Single Form Widget to be layout with CSS Grid, instead of table.
Created OFBIZ-12162 with patch for it.

Regards,
James


Reply | Threaded
Open this post in threaded view
|

Re: Single Form Widget on CSS Grid Layout

Nicolas Malin-2
Hello James,

I'm a little bit confused with your proposition, It's a direct conflict
with the separation between the model of a form and the way to rendering
it throw the theme.

If you want create a specific form for different display case maybe
check the extend logic OFBIZ-11335
<https://issues.apache.org/jira/browse/OFBIZ-11335>[1]

My feel is keep more simple as possible the form type code.

Nicolas

[1] https://issues.apache.org/jira/browse/OFBIZ-11335

On 26/01/2021 14:32, James Yong wrote:

> Hi all,
>
> Planning to add a new form widget type i.e. single_css-grid-layout.
> This new type allows Single Form Widget to be layout with CSS Grid, instead of table.
> Created OFBIZ-12162 with patch for it.
>
> Regards,
> James
>
>
Reply | Threaded
Open this post in threaded view
|

Re: Single Form Widget on CSS Grid Layout

Ingo Könemann
Hi all,

I looked at the patch and have some additional questions about these
changes.

 1. There are some added <span> elements I do not fully understand in
    the HtmlFormMacroLibrary.ftl template. Could you explain why they
    are necessary for the given proposition?
 2. It feels like using a Flexbox layout would be more appropriate for a
    modern look and feel. Is there a reason you implemented a CSS Grid
    instead of the as far as I know most commonly used system (see
    Bootstrap for example)? I think when modernizing the current user
    interface we would benefit more from a Flexbox implementation.

However, I do understand the need for modernization in the current user
interface.

Best regards,

Ingo


Am 26.01.21 um 17:59 schrieb Nicolas Malin:

> Hello James,
>
> I'm a little bit confused with your proposition, It's a direct conflict
> with the separation between the model of a form and the way to rendering
> it throw the theme.
>
> If you want create a specific form for different display case maybe
> check the extend logic OFBIZ-11335
> <https://issues.apache.org/jira/browse/OFBIZ-11335>[1]
>
> My feel is keep more simple as possible the form type code.
>
> Nicolas
>
> [1] https://issues.apache.org/jira/browse/OFBIZ-11335
>
> On 26/01/2021 14:32, James Yong wrote:
>> Hi all,
>>
>> Planning to add a new form widget type i.e. single_css-grid-layout.
>> This new type allows Single Form Widget to be layout with CSS Grid, instead of table.
>> Created OFBIZ-12162 with patch for it.
>>
>> Regards,
>> James
>>
Reply | Threaded
Open this post in threaded view
|

Re: Single Form Widget on CSS Grid Layout

Jacques Le Roux
Administrator
Hi Ingo,

Le 27/01/2021 à 08:12, Ingo Könemann a écrit :

> It feels like using a Flexbox layout would be more appropriate for a
>    modern look and feel.

Why do you feel so?

This should help: https://www.google.com/search?q=Flexbox+vs+css+grid&ie=UTF-8


> Is there a reason you implemented a CSS Grid
> instead of the as far as I know most commonly used system (see
> Bootstrap for example)?

I created OFBIZ-10444 2,5 years ago. There is there a link to an excellent article and other links to consider


> I think when modernizing the current user
>    interface we would benefit more from a Flexbox implementation.

Maybe both depending on context (CSS Grid for complete pages, Flexbox for contents) ? Some seems to recommend that...

Jacques

Reply | Threaded
Open this post in threaded view
|

Re: Single Form Widget on CSS Grid Layout

James Yong-2
In reply to this post by Nicolas Malin-2
Hi Nicholas,

Please see my reply inline..

Regards,
James

On 2021/01/26 16:59:25, Nicolas Malin <[hidden email]> wrote:
> Hello James,
>
> I'm a little bit confused with your proposition, It's a direct conflict
> with the separation between the model of a form and the way to rendering
> it throw the theme.

[James] Yes, it should be possible to do it at theme level. I was thinking having table-free forms at fundamental level, hence created another single type variant to move things gradually.  

>
> If you want create a specific form for different display case maybe
> check the extend logic OFBIZ-11335
> <https://issues.apache.org/jira/browse/OFBIZ-11335>[1]

[James] Ok, need to look into the usage again.

>
> My feel is keep more simple as possible the form type code.
>
> Nicolas
>
> [1] https://issues.apache.org/jira/browse/OFBIZ-11335
>
> On 26/01/2021 14:32, James Yong wrote:
> > Hi all,
> >
> > Planning to add a new form widget type i.e. single_css-grid-layout.
> > This new type allows Single Form Widget to be layout with CSS Grid, instead of table.
> > Created OFBIZ-12162 with patch for it.
> >
> > Regards,
> > James
> >
> >
>
Reply | Threaded
Open this post in threaded view
|

Re: Single Form Widget on CSS Grid Layout

James Yong-2
In reply to this post by Jacques Le Roux
Hi Ingo,

Some macros like renderTextFindField contains a number of fields. The addition of span tags will group these fields together so that they can be correctly placed next to the form field label.

I haven't looked info flexbox much. Thanks Jacques for the additional info.

Regards,
James

On 2021/01/27 11:30:42, Jacques Le Roux <[hidden email]> wrote:

> Hi Ingo,
>
> Le 27/01/2021 à 08:12, Ingo Könemann a écrit :
>
> > It feels like using a Flexbox layout would be more appropriate for a
> >    modern look and feel.
>
> Why do you feel so?
>
> This should help: https://www.google.com/search?q=Flexbox+vs+css+grid&ie=UTF-8
>
>
> > Is there a reason you implemented a CSS Grid
> > instead of the as far as I know most commonly used system (see
> > Bootstrap for example)?
>
> I created OFBIZ-10444 2,5 years ago. There is there a link to an excellent article and other links to consider
>
>
> > I think when modernizing the current user
> >    interface we would benefit more from a Flexbox implementation.
>
> Maybe both depending on context (CSS Grid for complete pages, Flexbox for contents) ? Some seems to recommend that...
>
> Jacques
>
>