get-size

WebJar for get-size

Лицензия

Лицензия

MIT
Группа

Группа

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

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

get-size
Последняя версия

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

2.0.3
Дата

Дата

Тип

Тип

jar
Описание

Описание

get-size
WebJar for get-size
Ссылка на сайт

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

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

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

https://github.com/desandro/get-size

Скачать get-size

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

<!-- https://jarcasting.com/artifacts/org.webjars.npm/get-size/ -->
<dependency>
    <groupId>org.webjars.npm</groupId>
    <artifactId>get-size</artifactId>
    <version>2.0.3</version>
</dependency>
// https://jarcasting.com/artifacts/org.webjars.npm/get-size/
implementation 'org.webjars.npm:get-size:2.0.3'
// https://jarcasting.com/artifacts/org.webjars.npm/get-size/
implementation ("org.webjars.npm:get-size:2.0.3")
'org.webjars.npm:get-size:jar:2.0.3'
<dependency org="org.webjars.npm" name="get-size" rev="2.0.3">
  <artifact name="get-size" type="jar" />
</dependency>
@Grapes(
@Grab(group='org.webjars.npm', module='get-size', version='2.0.3')
)
libraryDependencies += "org.webjars.npm" % "get-size" % "2.0.3"
[org.webjars.npm/get-size "2.0.3"]

Зависимости

Библиотека не имеет зависимостей. Это самодостаточное приложение, которое не зависит ни от каких других библиотек.

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

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

getSize

Get the size of elements. Used in Masonry, Isotope, & Flickity.

var size = getSize( elem );
// elem can be an element
var size = getSize( document.querySelector('.selector') )
// elem can be a selector string
var size = getSize('.selector')

Returns an object with:

  • width, height
  • innerWidth, innerHeight
  • outerWidth, outerHeight
  • paddingLeft, paddingTop, paddingRight, paddingBottom
  • marginLeft, marginTop, marginRight, marginBottom
  • borderLeftWidth, borderTopWidth, borderRightWidth, borderBottomWidth
  • isBorderBox

Browser support: IE10+, Android 4.0+, iOS 5+, and modern browsers

Install

Install with npm: npm install get-size

Install with Bower: bower install get-size

Firefox hidden iframe bug

Firefox has an old bug that occurs within iframes that are hidden with display: none. To resolve this, you can use alternate CSS to hide the iframe off-screen, with out display: none.

.hide-iframe {
  visibility: hidden;
  position: absolute;
  left: -999em;
}

MIT License

getSize is released under the MIT License.

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

Версия
2.0.3
2.0.2
1.2.2