Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

us-formly-templates

Package Overview
Dependencies
Maintainers
2
Versions
8
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

us-formly-templates - npm Package Compare versions

Comparing version 1.0.4 to 1.0.5

2

package.json
{
"name": "us-formly-templates",
"version": "1.0.4",
"version": "1.0.5",
"description": "Extensão com templates para usar formly com bootstrap",

@@ -5,0 +5,0 @@ "scripts": {

@@ -16,3 +16,3 @@ angular.module('usFormlyTemplates', [

name: 'validation',
types: ['input', 'maskedInput', 'cpf', 'rg', 'cnpj'],
types: ['input', 'maskedInput', 'cpf', 'rg', 'cnpj', 'number', 'fone', 'percent'],
template: `

@@ -105,7 +105,6 @@ <formly-transclude></formly-transclude>

name: 'rg',
//extends: 'maskedInput',
extends: 'input',
extends: 'maskedInput',
defaultOptions: {
templateOptions: {
//mask: '99.999.999-9',
mask: '99.999.999-9',
}

@@ -216,2 +215,27 @@ }

//Radio
formlyConfigProvider.setType({
name: 'radioDefault',
extends: 'radio',
template: `
<div class="checkbox" ng-repeat="(key, option) in to.options">
<label class="i-checks">
<input
type="radio"
id="{{id + '_'+ $index}}"
tabindex="0"
ng-value="option[to.valueProp || 'value']"
ng-model="model[options.key]">
<i></i>{{option[to.labelProp || 'name']}}
</label>
</div>`,
controller: function($scope){
// console.log($scope.model[$scope.options.key]);
if (!$scope.model[$scope.options.key]) {
$scope.model[$scope.options.key] = $scope.to.checked;
}
}
});
//Radio Inline

@@ -278,2 +302,17 @@ formlyConfigProvider.setType({

formlyConfigProvider.setType({
name: 'percent',
extends: 'input',
template: `
<input
ui-jq="TouchSpin"
ng-model="model[options.key]"
type="text"
class="form-control"
data-min='0'
data-step="0.1"
data-decimals="2"
data-postfix="%">`
});
// Select2

@@ -284,8 +323,8 @@ formlyConfigProvider.setType({

template: `
<ui-select ng-model="model[options.key]" required="{{to.required}}" ng-disabled="to.disabled" theme="bootstrap">
<ui-select ng-model="model[options.key]" required="{{to.required}}" ng-disabled="{{to.disabled}}" theme="bootstrap">
<ui-select-match placeholder="{{to.placeholder}}" allow-clear="true">{{$select.selected[to.labelProp]}}</ui-select-match>
<ui-select-choices repeat="option[to.valueProp] as option in to.options | filter: $select.search">
<div ng-bind-html="option[to.labelProp] | highlight: $select.search"></div>
<div ng-bind-html="option[to.labelProp] | highlight: $select.search"></div>
</ui-select-choices>
</ui-select>`
</ui-select>`
});

@@ -292,0 +331,0 @@

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc