Files
NapCatQQ/.pnpm-store/v3/files/4d/fb371c082670ee7afebf9ea0677418da400ee9104ac3660ed5519ad0104d00aea26f4d9bf55e36eda40c5d364610153c481f040a8b12940ede8b280cff9f5f
TanTan e311ca3275
Build NapCat Artifacts / Windows Loader Test (push) Canceled after 0s
Build NapCat Artifacts / Type Check & Test (push) Canceled after 0s
Build NapCat Artifacts / Build NapCat.Framework (push) Canceled after 0s
Build NapCat Artifacts / Build NapCat.Shell (push) Canceled after 0s
docs: 仓库链接指向本镜像仓库
2026-11-13 09:25:58 +08:00

40 lines
1.6 KiB
Plaintext

var $988353faa005faf8$exports = require("./useButton.main.js");
var $4M9F2$reactariautils = require("@react-aria/utils");
function $parcel$export(e, n, v, s) {
Object.defineProperty(e, n, {get: v, set: s, enumerable: true, configurable: true});
}
$parcel$export(module.exports, "useToggleButton", () => $c49208f7d2aac50b$export$51e84d46ca0bc451);
/*
* Copyright 2020 Adobe. All rights reserved.
* This file is licensed to you under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License. You may obtain a copy
* of the License at http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software distributed under
* the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS
* OF ANY KIND, either express or implied. See the License for the specific language
* governing permissions and limitations under the License.
*/
function $c49208f7d2aac50b$export$51e84d46ca0bc451(props, state, ref) {
const { isSelected: isSelected } = state;
const { isPressed: isPressed, buttonProps: buttonProps } = (0, $988353faa005faf8$exports.useButton)({
...props,
onPress: (0, $4M9F2$reactariautils.chain)(state.toggle, props.onPress)
}, ref);
return {
isPressed: isPressed,
isSelected: isSelected,
isDisabled: props.isDisabled || false,
buttonProps: (0, $4M9F2$reactariautils.mergeProps)(buttonProps, {
'aria-pressed': isSelected
})
};
}
//# sourceMappingURL=useToggleButton.main.js.map