UNPKG

repoweaver

Version:

A GitHub App that skillfully weaves multiple templates together to create and update repositories with intelligent merge strategies

1 lines 2.74 kB
{"ast":null,"code":"import UIManager from \"../../exports/UIManager\";\nimport useStable from \"../useStable\";\nexport default function usePlatformMethods(_ref) {\n var pointerEvents = _ref.pointerEvents,\n style = _ref.style;\n var ref = useStable(() => hostNode => {\n if (hostNode != null) {\n hostNode.measure = callback => UIManager.measure(hostNode, callback);\n hostNode.measureLayout = (relativeToNode, success, failure) => UIManager.measureLayout(hostNode, relativeToNode, failure, success);\n hostNode.measureInWindow = callback => UIManager.measureInWindow(hostNode, callback);\n }\n });\n return ref;\n}","map":{"version":3,"names":["UIManager","useStable","usePlatformMethods","_ref","pointerEvents","style","ref","hostNode","measure","callback","measureLayout","relativeToNode","success","failure","measureInWindow"],"sources":["/Users/pmouli/Documents/GitHub.nosync/boots-strapper/mobile/node_modules/react-native-web/dist/modules/usePlatformMethods/index.js"],"sourcesContent":["/**\n * Copyright (c) Nicolas Gallagher.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n *\n * \n */\n\nimport UIManager from '../../exports/UIManager';\nimport useStable from '../useStable';\n\n/**\n * Adds non-standard methods to the hode element. This is temporarily until an\n * API like `ReactNative.measure(hostRef, callback)` is added to React Native.\n */\nexport default function usePlatformMethods(_ref) {\n var pointerEvents = _ref.pointerEvents,\n style = _ref.style;\n // Avoid creating a new ref on every render.\n var ref = useStable(() => hostNode => {\n if (hostNode != null) {\n hostNode.measure = callback => UIManager.measure(hostNode, callback);\n hostNode.measureLayout = (relativeToNode, success, failure) => UIManager.measureLayout(hostNode, relativeToNode, failure, success);\n hostNode.measureInWindow = callback => UIManager.measureInWindow(hostNode, callback);\n }\n });\n return ref;\n}"],"mappings":"AASA,OAAOA,SAAS;AAChB,OAAOC,SAAS;AAMhB,eAAe,SAASC,kBAAkBA,CAACC,IAAI,EAAE;EAC/C,IAAIC,aAAa,GAAGD,IAAI,CAACC,aAAa;IACpCC,KAAK,GAAGF,IAAI,CAACE,KAAK;EAEpB,IAAIC,GAAG,GAAGL,SAAS,CAAC,MAAMM,QAAQ,IAAI;IACpC,IAAIA,QAAQ,IAAI,IAAI,EAAE;MACpBA,QAAQ,CAACC,OAAO,GAAGC,QAAQ,IAAIT,SAAS,CAACQ,OAAO,CAACD,QAAQ,EAAEE,QAAQ,CAAC;MACpEF,QAAQ,CAACG,aAAa,GAAG,CAACC,cAAc,EAAEC,OAAO,EAAEC,OAAO,KAAKb,SAAS,CAACU,aAAa,CAACH,QAAQ,EAAEI,cAAc,EAAEE,OAAO,EAAED,OAAO,CAAC;MAClIL,QAAQ,CAACO,eAAe,GAAGL,QAAQ,IAAIT,SAAS,CAACc,eAAe,CAACP,QAAQ,EAAEE,QAAQ,CAAC;IACtF;EACF,CAAC,CAAC;EACF,OAAOH,GAAG;AACZ","ignoreList":[]},"metadata":{"hasCjsExports":false},"sourceType":"module","externalDependencies":[]}