angular-rating-yo

WebJar for angular-rating-yo

Лицензия

Лицензия

MIT
Категории

Категории

Github Инструменты разработки Контроль версий Angular Взаимодействие с пользователем Веб-фреймворки
Группа

Группа

org.webjars.bower
Идентификатор

Идентификатор

github-com-sagarrabadiya-angular-rateyo
Последняя версия

Последняя версия

1.0.0
Дата

Дата

Тип

Тип

jar
Описание

Описание

angular-rating-yo
WebJar for angular-rating-yo
Ссылка на сайт

Ссылка на сайт

http://webjars.org
Система контроля версий

Система контроля версий

https://github.com/sagarrabadiya/angular-rateyo

Скачать github-com-sagarrabadiya-angular-rateyo

Как подключить последнюю версию

<!-- https://jarcasting.com/artifacts/org.webjars.bower/github-com-sagarrabadiya-angular-rateyo/ -->
<dependency>
    <groupId>org.webjars.bower</groupId>
    <artifactId>github-com-sagarrabadiya-angular-rateyo</artifactId>
    <version>1.0.0</version>
</dependency>
// https://jarcasting.com/artifacts/org.webjars.bower/github-com-sagarrabadiya-angular-rateyo/
implementation 'org.webjars.bower:github-com-sagarrabadiya-angular-rateyo:1.0.0'
// https://jarcasting.com/artifacts/org.webjars.bower/github-com-sagarrabadiya-angular-rateyo/
implementation ("org.webjars.bower:github-com-sagarrabadiya-angular-rateyo:1.0.0")
'org.webjars.bower:github-com-sagarrabadiya-angular-rateyo:jar:1.0.0'
<dependency org="org.webjars.bower" name="github-com-sagarrabadiya-angular-rateyo" rev="1.0.0">
  <artifact name="github-com-sagarrabadiya-angular-rateyo" type="jar" />
</dependency>
@Grapes(
@Grab(group='org.webjars.bower', module='github-com-sagarrabadiya-angular-rateyo', version='1.0.0')
)
libraryDependencies += "org.webjars.bower" % "github-com-sagarrabadiya-angular-rateyo" % "1.0.0"
[org.webjars.bower/github-com-sagarrabadiya-angular-rateyo "1.0.0"]

Зависимости

compile (2)

Идентификатор библиотеки Тип Версия
org.webjars.bower » jquery-rateyo jar [2.0.1,2.1)
org.webjars.bower : angular jar [1.4.1,1.5)

Модули Проекта

Данный проект не имеет модулей.

angular-rating-yo

Description

This directive allows you to enhance your rating feature in the application with behaviour from the jquery.rateyo library.

Requirements

Setup

  1. Install Grunt and Bower $ npm install -g grunt-cli bower
  2. Install development dependencies $ npm install
  3. Install components $ bower install
  4. ???
  5. Profit!

Usage

We use bower for dependency management. Install angular-rating-yo into your project by running the command

$ bower install angular-rating-yo

If you use a bower.json file in your project, you can have Bower save ui-select2 as a dependency by passing the --save flag with the above command.

This will copy the angular-rating-yo files into your bower_components folder, along with its dependencies. Load the script files in your application:

<link rel="stylesheet" href="bower_components/jquery-rateyo/src/jquery.rateyo.css">
<script type="text/javascript" src="bower_components/jquery/jquery.js"></script>
<script type="text/javascript" src="bower_components/jquery-rateyo/src/jquery.rateyo.js"></script>
<script type="text/javascript" src="bower_components/angular/angular.js"></script>
<script type="text/javascript" src="bower_components/angular-rating-yo/src/angular-rating-yo.js"></script>

(Note that jquery must be loaded before angular so that it doesn't use jqLite internally)

Add the rateYo module as a dependency to your application module:

var myAppModule = angular.module('MyApp', ['rateYo']);

Apply the directive to your rating elements:

<rate-yo on-set="set" on-change="change" ng-model="rating" read-only="options.readOnly" options="options"></rate-yo>

Options

All the rateYo options can be passed through the directive. You can read more about the supported list of options and what they do on the rateYo Documentation Page

myAppModule.controller('MyController', function($scope) {
     $scope.options = {
            ratedFill: '#f00',
            readOnly: false,
            halfStar: false,
            fullStar: false
        };
});
<rate-yo on-set="set" on-change="change" ng-model="rating" read-only="options.readOnly" options="options"></rate-yo>

Some times it may make sense to specify the options in the template file.

<rate-yo on-set="set" on-change="change" ng-model="rating" read-only="options.readOnly" options="{ratedFill: '#f00'}"></rate-yo>

Версии библиотеки

Версия
1.0.0