import 'package:get/get.dart';
import 'package:tone_snap/generated/assets.dart';
import 'package:tone_snap/routes/app_routes.dart';

class SettingsController extends GetxController {
  final options = ['Privacy Policy', 'Terms of Service'];
  final optionIcons = [Assets.sideBPrivacyPolicy, Assets.sideBTermsOfService];

  void onTapItem(int index) async {
    if (index == 0) {
      Get.toNamed(AppRoutes.privacy, arguments: {
        'title': options[index],
        'url': 'https://tonesnap-privacy.mystrikingly.com',
      });
    } else if (index == 1) {
      Get.toNamed(AppRoutes.terms, arguments: {
        'title': options[index],
        'url': 'https://tonesnap-terms.mystrikingly.com'
      });
    }
  }
}