(window.webpackJsonp=window.webpackJsonp||[]).push([[17],{315:function(t,v,_){"use strict";_.r(v);var e=_(15),s=Object(e.a)({},(function(){var t=this,v=t._self._c;return v("ContentSlotsDistributor",{attrs:{"slot-key":t.$parent.slotKey}},[v("h2",{attrs:{id:"sticky-概念"}},[v("a",{staticClass:"header-anchor",attrs:{href:"#sticky-概念"}},[t._v("#")]),t._v(" sticky 概念")]),t._v(" "),v("p",[t._v("粘性定位可以被认为是相对定位和固定定位的混合，元素在跨越特定阈值前为相对定位，之后为固定定位")]),t._v(" "),v("h2",{attrs:{id:"失效原因"}},[v("a",{staticClass:"header-anchor",attrs:{href:"#失效原因"}},[t._v("#")]),t._v(" 失效原因")]),t._v(" "),v("ul",[v("li",[t._v("必须指定 "),v("code",[t._v("top")]),t._v("、"),v("code",[t._v("bottom")]),t._v("、"),v("code",[t._v("left")]),t._v("、"),v("code",[t._v("right")]),t._v(" 之一")]),t._v(" "),v("li",[t._v("父元素必须指定高度，通常为 "),v("code",[t._v("height: 100%;")])]),t._v(" "),v("li",[t._v("父元素设置了 "),v("code",[t._v("overflow")]),t._v(" 属性")])]),t._v(" "),v("p",[t._v("::: warning\n"),v("strong",[t._v("父元素不单单指元素直系的父元素，任意引用了次组件的父组件元素也包括")]),t._v("\n:::")]),t._v(" "),v("hr")])}),[],!1,null,null,null);v.default=s.exports}}]);