var xpath = function(path, node, tag) { node = node || document; tag = tag || '*'; var patterns = "", xhtmlNamespace = "http://www.w3.org/1999/xhtml", namespaceResolver = (document.documentElement.namespaceURI === xhtmlNamespace)? xhtmlNamespace : null, returnElements = [], elements, _node;
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var keyOf = function(oneKeyObj) { | |
var key; | |
for (key in oneKeyObj) { | |
if (!oneKeyObj.hasOwnProperty(key)) { | |
continue; | |
} | |
return key; | |
} | |
return null; | |
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
_ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
```javascript | |
// find sub Match; | |
var lex = (function(){ | |
var ignoredRef = /\(\?\!|\(\?\:|\?\=/; | |
var slice = [].slice; | |
var wrapHander = function(handler){ | |
return function(all){ | |
return { | |
type: handler, | |
value: all |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function isSupportFixed() { | |
var userAgent = window.navigator.userAgent, | |
ios = userAgent.match(/(iPad|iPhone|iPod)\s+OS\s([\d_\.]+)/), | |
ios5below = ios && ios[2] && (parseInt(ios[2].replace(/_/g, '.'), 10) < 5), | |
operaMini = /Opera Mini/i.test(userAgent), | |
body = document.body, | |
div, isFixed; | |
div = document.createElement('div'); | |
div.style.cssText = 'display:none;position:fixed;z-index:100;'; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!doctype html> | |
<html> | |
<head> | |
<!-- Run in full-screen mode. --> | |
<meta name="apple-mobile-web-app-capable" content="yes"> | |
<!-- Make the status bar black with white text. --> | |
<meta name="apple-mobile-web-app-status-bar-style" content="black"> |
W3C Introduction to Web Components - explainer/overview of the technologies
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Top-level build file where you can add configuration options common to all sub-projects/modules. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?xml version="1.0" encoding="UTF-8"?> | |
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd"> | |
<plist version="1.0"> | |
<dict> | |
<key>comment</key> | |
<string>MCSS</string> | |
<key>fileTypes</key> | |
<array> | |
<string>mcss</string> | |
<string>css</string> |
http://leeluolee.github.io/mcss/ 这里虽然很简陋 ,但是可以在这里测试下。
%
在mcss里是类似&
的东西即预制符(与SASS中的意义不一样), 只是会除去顶层选择器的
很多场景下,我们需要扩展类型比如一个.m-form
的表单模块,我们需要通过扩展类.m-form-stack
来修改一个表单模块内的元素,即一个节点同时写两个名称m-form m-form-stack
,这种增量扩展类的写法应该也是目前类型bootstrap的css框架的选择。
这时我们可以这样做
NewerOlder