10-07-2018, 02:36 PM
Captain Kudzu,
I have made changes to TIWBSRegion that I would like you to consider adding to the source code that you distribute as part of IW.
As you know, the following code is perfectly acceptable and normal with Bootstrap 3:
<button type="button" class="navbar-toggle" data-toggle="collapse" data-target="#myNavbar">
<span class="icon-bar"></span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
</button>
But TIWBSButton descends from TIWBSCustomControl, which descends from TIWCustomControl and implements the interface IIWBSComponent. As such it cannot act as a container. I have written about this problem before.
I have realized that this problem needs an immediately solution. TIWBSButton can remain, but I needed BSRegion to be usable as a span and as a button. Hence my changes:
type
TIWBSRegionTagType = (bsttDiv, bsttH1, bsttH2, bsttH3, bsttH4, bsttH5, bsttH6, bsttP, bsttSpan, bsttButton);
const
aIWBSRegionTagType: array[bsttDiv..bsttButton] of string = ('div', 'h1', 'h2', 'h3', 'h4', 'h5', 'h6', 'p', 'span', 'button');
Without these changes I cannot use Delphi and IntraWeb to realize my designs, unless I go with Templates. But that's not the point -- the point is that I want to use IWBootstrap, if for no other reason than to prove that it can be done for any design, not just simple ones.
If I am missing something, please help me understand.
Loren
I have made changes to TIWBSRegion that I would like you to consider adding to the source code that you distribute as part of IW.
As you know, the following code is perfectly acceptable and normal with Bootstrap 3:
<button type="button" class="navbar-toggle" data-toggle="collapse" data-target="#myNavbar">
<span class="icon-bar"></span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
</button>
But TIWBSButton descends from TIWBSCustomControl, which descends from TIWCustomControl and implements the interface IIWBSComponent. As such it cannot act as a container. I have written about this problem before.
I have realized that this problem needs an immediately solution. TIWBSButton can remain, but I needed BSRegion to be usable as a span and as a button. Hence my changes:
type
TIWBSRegionTagType = (bsttDiv, bsttH1, bsttH2, bsttH3, bsttH4, bsttH5, bsttH6, bsttP, bsttSpan, bsttButton);
const
aIWBSRegionTagType: array[bsttDiv..bsttButton] of string = ('div', 'h1', 'h2', 'h3', 'h4', 'h5', 'h6', 'p', 'span', 'button');
Without these changes I cannot use Delphi and IntraWeb to realize my designs, unless I go with Templates. But that's not the point -- the point is that I want to use IWBootstrap, if for no other reason than to prove that it can be done for any design, not just simple ones.
If I am missing something, please help me understand.
Loren