New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

ngSinaEmoji

Package Overview
Dependencies
Maintainers
1
Versions
7
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

ngSinaEmoji

sina emoji components of Angular

  • 0.1.5
  • latest
  • Source
  • npm
  • Socket score

Version published
Maintainers
1
Created
Source

ngSinaEmoji

整合新浪远程表情组件 ####Useage

$ npm install ngSinaEmoji
var Demo = angular.module('Demo',['ngSinaEmoji'])
// 必须要绑定model
 <textarea ng-model="emoji" ng-sina-emoji target="#emotion" app-key="1362404091" cols="50" rows="5"></textarea>
<button id="emotion">表情</button>
Params
keyvalue
target事件触发元素,必填
appKey新浪授权ID(可不填,有默认ID)
Service
        .controller('EmojiCtrl',function ($scope,SinaEmoji) {
            $scope.destroy = function(){
                // 销毁实例
                SinaEmoji.destroy();
                // 解析表情
                SinaEmoji.parseEmotions(value)
            }
        })
        //常常使用过滤器来解析
        .filter('parseEmotions',function (SinaEmoji,$sce) {
            return function (value) {
                return $sce.trustAsHtml(SinaEmoji.parseEmotions(value));
            }
        })
// html
<p ng-bind-html="emoji | parseEmotions"></p>

Keywords

FAQs

Package last updated on 22 Aug 2016

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

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