Comments (9)
How does the rendered content look like (html)?
from yii2-bootstrap5.
The code view:
<div class="col-md-6">
<?= $form->field($model, 'active')->checkBox( ['switch' => True] ) ?>
</div>
is rendered like this:
<div class="form-group field-user-active">
<input type="hidden" name="User[active]" value="0"><label><input type="checkbox" id="user-active" name="User[active]" value="1" switch> Active</label>
<div class="help-block"></div>
</div>
from yii2-bootstrap5.
Do you override the default template of the active-fields, e.g in active-form?
from yii2-bootstrap5.
No: nothing at all.
I've only issued: /usr/local/bin/composer create-project --prefer-dist yiisoft/yii2-app-advanced testapp, and it came to pass that BS5 was installed.
BTW: I've tested:
yii\bootstrap5\Progress::widget( ['percent' => 50, 'label' => '50%', 'class' => 'pogress-bar'] );
and it runs flawlessly.
from yii2-bootstrap5.
@numitec can you display more sources? maybe you change template or something like this?
from yii2-bootstrap5.
@WinterSilence I resolved using SwitchInput from kartik library:
use kartik\switchinput\SwitchInput;
...
<?= $form->field($model, 'active')->widget( SwitchInput::classname(), [] ); ?>
from yii2-bootstrap5.
@numitec sorry but its look like fake - your example in unit test
from yii2-bootstrap5.
@WinterSilence, I didn't quite follow you. Could you elaborate it?
from yii2-bootstrap5.
@numitec https://github.com/yiisoft/yii2-bootstrap5/blob/master/tests/ActiveFieldTest.php#L173
from yii2-bootstrap5.
Related Issues (20)
- yii\bootstrap5\Breadcrumbs problem HOT 2
- kartik Gridview widget problem with bootstrap5 HOT 2
- Translation re-factoring HOT 1
- Dropdown clientEvents do not fire HOT 2
- Missing css files while including `yii\bootstrap5\BootstrapPluginAsset` HOT 4
- Version 2.0.4 not working \kartik\datecontrol\DateControl HOT 3
- Navbar cannot accept collapseOptions = false
- Curious about card implementation
- ActiveForm | Incorrect radioList HTML/CSS
- Dropdown template is incorrect HOT 2
- Bootstrap5 Button is not registering clientEvents HOT 4
- invalid-feedback div breaks inline radio list
- Use both bs3 and bs5 in the same project HOT 4
- Add brandImageOptions to NavBar.php to ensure accessibility.
- Whole Bootstrap directory is published into web/assets
- Replace `bower-asset/bootstrap` => `npm-asset/bootstrap`. HOT 1
- Missing package twbs/boostrap-icons in composer.json HOT 2
- Switch to NPM and drop Bower? HOT 1
- no error text when use inputTemplate
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from yii2-bootstrap5.