A directive for creating resizable containers.
All other resizable directive concepts I came across include layout logic in the directive. I wanted a directive that only handled the resize logic. This way, the layout logic is quarantined to the CSS.
npm install angular-resizable
or bower install angular-resizable
or clone/download this repoangular-resizable.min.js
in your project.angular-resizable.min.css
in your project as well (this provides default styling for the resize handles).angular.module('app', ['angularResizable'])
<section resizable r-directions="['bottom', 'right']" r-flex="true">
Include any sides you want to be resizable in an array inside r-directions
. Accepts 'top','right','bottom', and 'left'. You can style the handles however you want. Just override the styles in the css in your own stylesheet.
Attributes | Default | Accepts | Description |
---|---|---|---|
rDirections | ['right'] | ['top', 'right', 'bottom', 'left',] | Determines which sides of the element are resizable. |
rFlex | false | boolean | Set as true if you are using flexbox. See this codepen. |
rCenteredX | false | boolean | If set as true, the velocity of horizontal resizing will be doubled. |
rCenteredY | false | boolean | If set as true, the velocity of vertical resizing will be doubled. |
rWidth | false | integer or $scope variable | If set, the resizable element will be rendered with a predefined width relative to this value in pixels and a watcher will be set on the 'rWidth' attribute. See this codepen. |
rHeight | false | integer or $scope variable | If set, the resizable element will be rendered with a predefined height relative to this value in pixels and a watcher will be set on the 'rHeight' attribute. See this codepen. |
rGrabber | <span></span> |
string | Defines custom inner html for the grabber. |
rNoThrottle | false | boolean | Disables angular-resizable.resizing throttling (see events section below). |
For an example using the events, see this codepen.
This event is emitted at the beginning of a resize with the following info object:
info.width
: The width of the directive at time of resize start. Will be false if resizing verticallyinfo.height
: The height of the directive at time of resize start. Will be false if resizing horizontallyinfo.id
: The id of the directive. Will be false if there is no id set.info.evt
: original mouse event objectCalled repeatedly while the mouse is being moved. By default, only calls once every 100ms to keep CPU usage low. For smooth resizing, use the rNoThrottle
attribute. This event is emitted during the resizing of the element with the following object as an argument:
info.width
: The width of the directive at time of resize end. Will be false if resizing verticallyinfo.height
: The height of the directive at time of resize end. Will be false if resizing horizontallyinfo.id
: The id of the directive. Will be false if there is no id set.info.evt
: original mouse event objectThis event is emitted at the end of a resize with the following object as an argument:
info.width
: The width of the directive at time of resize end. Will be false if resizing verticallyinfo.height
: The height of the directive at time of resize end. Will be false if resizing horizontallyinfo.id
: The id of the directive. Will be false if there is no id set.info.evt
: original mouse event objectMIT
https://github.com/angular-ui/bootstrap table所有相关: http://bazalt-cms.com/ng-table/ https://github.com/esvit/ng-table https://github.com/angular-ui/ng-grid http://bazalt-cms.com/ng-table/example/3 http
https://github.com/angular-ui/ui-grid/wiki/Templating $scope.gridOptions = { data: self.myData, enableCellEditOnFocus: true, //enables the editor on a single click, if you use enableCellEdit:
Angular 是一款十分流行且好用的 Web 前端框架,目前由 Google 维护。这个条目收录的是 Angular 2 及其后面的版本。由于官方已将 Angular 2 和之前的版本 Angular.js 分开维护(两者的 GitHub 地址和项目主页皆不相同),所以就有了这个页面。传送门:Angular.js 特性 跨平台 渐进式 Web 应用 借助现代化 Web 平台的力量,交付 app
即将到来的Angular 2框架是使用TypeScript开发的。 因此Angular和TypeScript一起使用非常简单方便。 Angular团队也在其文档里把TypeScript视为一等公民。 正因为这样,你总是可以在Angular 2官网(或Angular 2官网中文版)里查看到最新的结合使用Angular和TypeScript的参考文档。 在这里查看快速上手指南,现在就开始学习吧!
从头开始创建项目 lint你的代码 运行您的单元测试和端到端测试。 Angular 2 CLI目前只在TypeScript中生成框架,稍后还会有其他版本。
这小节内容是译者加的,因为我认为对于新手而言,学习一个框架是有成本的,特别是对于一个不算简单的技术来说,我希望这篇教程是对新手友好的,所以我首先要让你放心的将时间和精力投入到Angular2 中。那我们先不谈技术细节,先用数据说话。 这里我多说一句,最近看一些文章中谷歌趋势截图,大都没有把范围限定在“编程”上。图中可以看出Vue2非常少,所以在下面比较中不再单独统计。 教程数量 这里我选取的主要是
我们已经在Highcharts Configuration Syntax一章中看到了用于绘制图表的配置 。 下面给出角度计图表的示例。 配置 (Configurations) 现在让我们看一下所采取的其他配置/步骤。 chart.type 将图表类型配置为基于计量。 将类型设置为“规格”。 var chart = { type: 'guage' }; pane 此类型仅适用于极坐标图和角度
角度计图表用于绘制仪表/仪表类型图表。 在本节中,我们将讨论不同类型的角度计图表。 Sr.No. 图表类型和描述 1 角度计 角度表。 2 实心仪表 实心图表。 3 Clock 时钟。 4 带双轴的仪表 带双轴的仪表图。 5 VU表 VU表图表。