本文整理匯總了TypeScript中@ephox/sugar.Compare.eq方法的典型用法代碼示例。如果您正苦於以下問題:TypeScript Compare.eq方法的具體用法?TypeScript Compare.eq怎麽用?TypeScript Compare.eq使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類@ephox/sugar.Compare
的用法示例。
在下文中一共展示了Compare.eq方法的10個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的TypeScript代碼示例。
示例1: getParentCaption
return getParentCaption(rootElm, Element.fromDom(to.getNode())).map((toCaption) => {
return Compare.eq(toCaption, fromCaption) === false;
});
示例2: function
return function (element) {
return Compare.eq(element, getBody(editor));
};
示例3: getParentCell
return getParentCell(rootElm, Element.fromDom(to.getNode())).map((toCell) => {
return Compare.eq(toCell, fromCell) === false;
});
示例4: function
DomEvent.bind(editorApi.doc(), 'touchend', function (touchEvent) {
if (Compare.eq(editorApi.html(), touchEvent.target()) || Compare.eq(editorApi.body(), touchEvent.target())) {
// IosHacks.setSelectionAtTouch(editorApi, touchEvent);
}
}),
示例5: function
}, function (e) {
return Compare.eq(e, Element.fromDom(editor.getBody()));
}).getOr(0);
示例6:
.bind(function (endParentTable) {
return Compare.eq(startParentTable, endParentTable) ? Option.some(startParentTable) : Option.none();
});
示例7: dropLast
return dropLast(Traverse.parents(startNode, function (elm) {
return predicate(elm) || Compare.eq(elm, rootElm);
}));
示例8:
const closest = SelectorFind.closest(newStart, selector, (n) => {
return Compare.eq(n, root);
});
示例9: function
const isRoot = function (element) {
const name = Node.name(element);
return Compare.eq(element, body) || Arr.contains(rootElements, name);
};
示例10: function
const parents = Traverse.parents(block, function (elm) {
return Compare.eq(elm, toBlock);
});