65 lines
3.8 KiB
TypeScript
65 lines
3.8 KiB
TypeScript
/* Metro module 12809; source: design/components/Slider/native/Slider.native.tsx; dependencies: [31, 27, 33, 4501, 697, 4081, 4082, 7992, 2] */
|
|
function _fun97683(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#97683, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12999:6, offset: 0x0218d430, size: 356 bytes, params: 8, frame: 22
|
|
var object2;
|
|
const env0_0 = require;
|
|
const Object = global.Object;
|
|
Object.defineProperty(exports, '__esModule', {value: true});
|
|
const env0_3 = importAll(31) /* metro dependency 31 */;
|
|
const env0_4 = (require(27) /* metro dependency 27 */).View;
|
|
let value = require(33) /* metro dependency 33 */;
|
|
const env0_5 = value.jsx;
|
|
const env0_6 = value.jsxs;
|
|
value = require(4501) /* metro dependency 4501: createStyles */;
|
|
const createStyles = value.createStyles;
|
|
object2 = {container: {'flex': 1, 'flexDirection': 'row', 'alignItems': 'center'}};
|
|
object2.slider = {flex: 1};
|
|
const REDESIGN_INPUT_CONTROL_SELECTED = (importDefault(697) /* metro dependency 697: native */).colors.REDESIGN_INPUT_CONTROL_SELECTED;
|
|
object2.minimumTrackTintColor = {backgroundColor: REDESIGN_INPUT_CONTROL_SELECTED};
|
|
const SLIDER_TRACK_BACKGROUND = (importDefault(697) /* metro dependency 697: native */).colors.SLIDER_TRACK_BACKGROUND;
|
|
object2.maximumTrackTintColor = {backgroundColor: SLIDER_TRACK_BACKGROUND};
|
|
let PX_8 = (importDefault(697) /* metro dependency 697: native */).space.PX_8;
|
|
object2.startIcon = {marginRight: PX_8};
|
|
PX_8 = (importDefault(697) /* metro dependency 697: native */).space.PX_8;
|
|
object2.endIcon = {marginLeft: PX_8};
|
|
const env0_7 = Reflect.apply(createStyles, value, [object2]);
|
|
(require(2) /* metro dependency 2 */).fileFinishedImporting('design/components/Slider/native/Slider.native.tsx');
|
|
exports.Slider = Slider;
|
|
}
|
|
|
|
function Slider(a0) { // fn#97684, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12999:590, offset: 0x0218d594, size: 389 bytes, params: 2, frame: 28
|
|
const startIcon = a0.startIcon;
|
|
const endIcon = a0.endIcon;
|
|
const style = a0.style;
|
|
const onValueChange = a0.onValueChange;
|
|
const step = a0.step;
|
|
const object2 = {'startIcon': 0, 'endIcon': 0, 'style': 0, 'onValueChange': 0, 'step': 0};
|
|
const value = null;
|
|
silentSetPrototypeOf(object2, value, undefined);
|
|
const value2 = copyDataProperties({}, a0, object2, undefined);
|
|
const styles = useStyles();
|
|
const value4 = env0_3.useCallback(_fun97685, [step, onValueChange]);
|
|
const items2 = [value != startIcon ? <View style={styles.startIcon}>{startIcon}</View> : value];
|
|
items2[1] = ((Component) => <Component {...value2} {...{['style']: [styles.slider,
|
|
style]}} {...{['step']: step}} {...{['onValueChange']: value4}} {...{['minimumTrackTintColor']: styles.minimumTrackTintColor.backgroundColor}} {...{['maximumTrackTintColor']: styles.maximumTrackTintColor.backgroundColor}} {...{['tapToSeek']: true}} />)(importDefault(7992) /* metro dependency 7992 */);
|
|
items2[2] = value != endIcon ? <View style={styles.endIcon}>{endIcon}</View> : value;
|
|
return (
|
|
<View style={styles.container}>
|
|
{items2}
|
|
</View>
|
|
);
|
|
}
|
|
|
|
function _fun97685(a0) { // fn#97685, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12999:694, offset: 0x0218d719, size: 97 bytes, params: 2, frame: 16
|
|
var value2;
|
|
var moduleValue;
|
|
if (step != null) {
|
|
value2 = environment.__proto__;
|
|
moduleValue = require(4081) /* metro dependency 4081: HapticUtilsNative */;
|
|
moduleValue.triggerHapticFeedback((importDefault(4082) /* metro dependency 4082: HapticFeedbackTypes */).IMPACT_LIGHT);
|
|
}
|
|
if (onValueChange != null) {
|
|
onValueChange(a0);
|
|
}
|
|
}
|
|
|