I was hoping someone would be able to point me in the right direction for how to size the create dialog? My ascx file requires more space than the standard simple.ascx, and the scrollbars that are presently there make it pretty difficult to use. I haven't been able to find much information about using a custom usercontrol in the create dialog...
Just a wild guess and not being an expert at this, but me thinks you'll have to take a look at the styles being used in the create dialog and change the css accordingly.
I also figured that would be the case, but I don't see anything in the usercontrol that would lend its self to that - no specific IDs or Classes that would control the overall height...
I appreciate the thought though... perhaps Niels, Per, or Tim might weigh in here... (I've built everything else from Tim's excellent umbraco.tv videos so far)
The create member dialog also has some more fields and that has a correct size (no scrollbars). So it might be good to check out the source for that usercontrol (/umbraco/create/member.ascx).
Ok, was intrigued by your question and wanted to find the answer... found it... need to edit the createNew() javascript function in umbracoDefault.js.
And as tim pointed out, there's a else branch that checks whether you want to create a new member (alias = initmember from ui.xml) and sets the height of the modal box accordingly.
This is an intersting topic, meaning, the topic of modals. Especially as it related to the "Choose Media..." modal. Given what you posted above Dirk, I'll check out the possibility of changing the pick media one as well.
I'd noticed the same thing, sizes being set in umbracoDefault.js.
The reason I ask is that I am developing an eCommerce solution for umbraco (to be released as OSS on codeplex - name pending, I want to make sure it is distinct from the awesome commercial uCommerce package) and was trying to determine how I can facilitate the creation of items when there are multiple required fields. I want to keep all of the maintenance of the commerce items inside of the umbraco admin.
Since this would be packaged up, would it be possible or advisable to modify umbracoDefault.js? If not, then the only way I see is to try to resize the parent container from inside the iframed usercontrol via jQuery - but this also seems inadvisable.
I would advise against modifying the Umbraco source. What we did for uCommerce is limit the input needed in the dialogs and instead go for input in the dashboard itself. Usually we only ask for a name or identifier in the dialogs and leave everything else for the dashboard. Works quite well and you avoid the running into space limitation of the dialog UI.
Hi Soren! Nice to hear from you, and from someone in a similar situation in more ways than one! Since this question, I have taken the same path you indicated. I save default values instead of asking for them all in the dialog. I also agree that modifying the umbraco source really seems like a bad idea for a package to do. Going forward, I would love to see an extensible way for being able to specify the width and height of that dialog, but certainly for now it is usable as you suggested, and that is the path I will continue to take.
Create Dialog for Custom Tree (size)
I was hoping someone would be able to point me in the right direction for how to size the create dialog? My ascx file requires more space than the standard simple.ascx, and the scrollbars that are presently there make it pretty difficult to use. I haven't been able to find much information about using a custom usercontrol in the create dialog...
Thanks,
Scott
Just a wild guess and not being an expert at this, but me thinks you'll have to take a look at the styles being used in the create dialog and change the css accordingly.
Cheers,
/Dirk
Thanks Dirk,
I also figured that would be the case, but I don't see anything in the usercontrol that would lend its self to that - no specific IDs or Classes that would control the overall height...
I appreciate the thought though... perhaps Niels, Per, or Tim might weigh in here... (I've built everything else from Tim's excellent umbraco.tv videos so far)
Thanks,
Scott
Comment author was deleted
Hi Scott,
The create member dialog also has some more fields and that has a correct size (no scrollbars). So it might be good to check out the source for that usercontrol (/umbraco/create/member.ascx).
Cheers,
Tim
Ok, was intrigued by your question and wanted to find the answer... found it... need to edit the createNew() javascript function in umbracoDefault.js.
And as tim pointed out, there's a else branch that checks whether you want to create a new member (alias = initmember from ui.xml) and sets the height of the modal box accordingly.
Hope this helps.
Regards,
/Dirk
This is an intersting topic, meaning, the topic of modals. Especially as it related to the "Choose Media..." modal. Given what you posted above Dirk, I'll check out the possibility of changing the pick media one as well.
Thanks!
-- Nik
I'd noticed the same thing, sizes being set in umbracoDefault.js.
The reason I ask is that I am developing an eCommerce solution for umbraco (to be released as OSS on codeplex - name pending, I want to make sure it is distinct from the awesome commercial uCommerce package) and was trying to determine how I can facilitate the creation of items when there are multiple required fields. I want to keep all of the maintenance of the commerce items inside of the umbraco admin.
Since this would be packaged up, would it be possible or advisable to modify umbracoDefault.js? If not, then the only way I see is to try to resize the parent container from inside the iframed usercontrol via jQuery - but this also seems inadvisable.
I would advise against modifying the Umbraco source. What we did for uCommerce is limit the input needed in the dialogs and instead go for input in the dashboard itself. Usually we only ask for a name or identifier in the dialogs and leave everything else for the dashboard. Works quite well and you avoid the running into space limitation of the dialog UI.
Hope this helps.
Hi Soren! Nice to hear from you, and from someone in a similar situation in more ways than one! Since this question, I have taken the same path you indicated. I save default values instead of asking for them all in the dialog. I also agree that modifying the umbraco source really seems like a bad idea for a package to do. Going forward, I would love to see an extensible way for being able to specify the width and height of that dialog, but certainly for now it is usable as you suggested, and that is the path I will continue to take.
is working on a reply...