Skip to content

Commit

Permalink
quest fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
phillipthelen committed Jan 21, 2025
1 parent 5c0ec29 commit ac565af
Show file tree
Hide file tree
Showing 5 changed files with 34 additions and 33 deletions.
20 changes: 7 additions & 13 deletions HabitRPG/Storyboards/Base.lproj/Social.storyboard
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
<?xml version="1.0" encoding="UTF-8"?>
<document type="com.apple.InterfaceBuilder3.CocoaTouch.Storyboard.XIB" version="3.0" toolsVersion="32700.99.1234" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" colorMatched="YES">
<document type="com.apple.InterfaceBuilder3.CocoaTouch.Storyboard.XIB" version="3.0" toolsVersion="23504" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" colorMatched="YES">
<device id="retina4_7" orientation="portrait" appearance="light"/>
<dependencies>
<deployment identifier="iOS"/>
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="22685"/>
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="23506"/>
<capability name="System colors in document resources" minToolsVersion="11.0"/>
<capability name="documents saved in the Xcode 8 format" minToolsVersion="8.0"/>
</dependencies>
Expand Down Expand Up @@ -502,7 +502,6 @@
</userDefinedRuntimeAttribute>
</userDefinedRuntimeAttributes>
<connections>
<action selector="forceStartButtonTapped:" destination="h0f-kS-d60" eventType="touchUpInside" id="xcv-MT-HSH"/>
<action selector="leaveButtonTapped:" destination="h0f-kS-d60" eventType="touchUpInside" id="5im-hy-8pD"/>
</connections>
</button>
Expand Down Expand Up @@ -689,7 +688,7 @@
<nil key="highlightedColor"/>
</label>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="999" verticalCompressionResistancePriority="1000" text="" textAlignment="natural" lineBreakMode="tailTruncation" numberOfLines="0" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="mVE-dK-Vtq">
<rect key="frame" x="30" y="23" width="282" height="20"/>
<rect key="frame" x="30" y="23" width="282" height="0.0"/>
<constraints>
<constraint firstAttribute="height" priority="500" constant="15" id="qCi-zd-vPi"/>
</constraints>
Expand All @@ -698,13 +697,13 @@
<nil key="highlightedColor"/>
</label>
<button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" buttonType="system" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="5M1-O7-8SK">
<rect key="frame" x="312" y="11" width="63" height="36"/>
<rect key="frame" x="312" y="11" width="63" height="16"/>
<constraints>
<constraint firstAttribute="width" constant="63" id="9yQ-jK-eHb"/>
</constraints>
</button>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="1000" verticalHuggingPriority="1000" horizontalCompressionResistancePriority="1000" verticalCompressionResistancePriority="1000" text="" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="o36-K8-WE9">
<rect key="frame" x="345" y="55" width="0.0" height="0.0"/>
<rect key="frame" x="345" y="35" width="0.0" height="0.0"/>
<constraints>
<constraint firstAttribute="width" priority="500" constant="42" id="iXX-nv-dQm"/>
<constraint firstAttribute="height" priority="500" constant="21" id="pg6-HC-x8e"/>
Expand All @@ -714,14 +713,14 @@
<nil key="highlightedColor"/>
</label>
<imageView userInteractionEnabled="NO" contentMode="scaleToFill" horizontalHuggingPriority="251" verticalHuggingPriority="251" translatesAutoresizingMaskIntoConstraints="NO" id="Bzg-8o-qvO">
<rect key="frame" x="325" y="47" width="16" height="16"/>
<rect key="frame" x="325" y="27" width="16" height="16"/>
<constraints>
<constraint firstAttribute="height" constant="16" id="nYL-bH-Geh"/>
<constraint firstAttribute="width" constant="16" id="wMZ-47-REq"/>
</constraints>
</imageView>
<view userInteractionEnabled="NO" contentMode="scaleToFill" verticalHuggingPriority="1000" verticalCompressionResistancePriority="1000" translatesAutoresizingMaskIntoConstraints="NO" id="ydi-2t-xFg" customClass="TagListView" customModule="TagListView">
<rect key="frame" x="30" y="55" width="287" height="20"/>
<rect key="frame" x="30" y="35" width="287" height="40"/>
<color key="backgroundColor" white="0.0" alpha="0.0" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
<constraints>
<constraint firstAttribute="height" priority="500" constant="20" id="S4z-Nh-ULl"/>
Expand Down Expand Up @@ -2681,11 +2680,6 @@
<point key="canvasLocation" x="4542" y="1415"/>
</scene>
</scenes>
<designables>
<designable name="ydi-2t-xFg">
<size key="intrinsicContentSize" width="287" height="20"/>
</designable>
</designables>
<inferredMetricsTieBreakers>
<segue reference="jzO-TO-nUb"/>
<segue reference="71z-UW-WBb"/>
Expand Down
9 changes: 7 additions & 2 deletions HabitRPG/UI/Purchases/SubscriptionOptionViewUI.swift
Original file line number Diff line number Diff line change
Expand Up @@ -104,8 +104,13 @@ struct SubscriptionOptionViewUI<Price: View, Recurring: View, Tag: View>: View {
Image(Asset.plus.name).renderingMode(.template).foregroundColor(isSelected ? Color.yellow100 : .purple400)
if gemCapMax {
Group {
Text("Max ") +
Text("Gem Cap").fontWeight(.bold).foregroundColor(isSelected ? Color.yellow5 : .white)
if isGift {
Text("They instantly start at the max ") +
Text("Gem Cap").fontWeight(.bold).foregroundColor(isSelected ? Color.yellow5 : .white)
} else {
Text("Max ") +
Text("Gem Cap").fontWeight(.bold).foregroundColor(isSelected ? Color.yellow5 : .white)
}
}.multilineTextAlignment(.leading)
} else {
Group {
Expand Down
3 changes: 3 additions & 0 deletions HabitRPG/Utilities/UserManager.swift
Original file line number Diff line number Diff line change
Expand Up @@ -158,6 +158,9 @@ class UserManager: NSObject {
Analytics.setUserProperty(user.isSubscribed ? "true" : "false", forName: "is_subscribed")
Analytics.setUserProperty(user.party?.id != nil ? "true" : "false", forName: "has_party")
Analytics.setUserProperty("\(user.loginIncentives)", forName: "checkin_count")
if let notifs = user.preferences?.pushNotifications {
Analytics.setUserProperty("\(notifs)", forName: "allowed_push_notifications")
}
#endif
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@ import ReactiveSwift

public class LeaveQuestCall: ResponseObjectCall<EmptyResponseProtocol, APIEmptyResponse> {
public init(groupID: String) {

super.init(httpMethod: .POST, endpoint: "groups/\(groupID)/quest/leave", postData: nil)
super.init(httpMethod: .POST, endpoint: "groups/\(groupID)/quests/leave", postData: nil)
}
}
32 changes: 16 additions & 16 deletions Habitica.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -4091,7 +4091,7 @@
"@executable_path/Frameworks",
);
MACOSX_DEPLOYMENT_TARGET = 13.0;
MARKETING_VERSION = 3.12.2;
MARKETING_VERSION = 3.12.3;
OTHER_LDFLAGS = (
"-ObjC",
"-framework",
Expand Down Expand Up @@ -4235,7 +4235,7 @@
"@executable_path/Frameworks",
"@executable_path/../../Frameworks",
);
MARKETING_VERSION = 3.12.2;
MARKETING_VERSION = 3.12.3;
MTL_ENABLE_DEBUG_INFO = NO;
MTL_FAST_MATH = YES;
OTHER_LDFLAGS = "$(inherited)";
Expand Down Expand Up @@ -4277,7 +4277,7 @@
"@executable_path/Frameworks",
"@executable_path/../../Frameworks",
);
MARKETING_VERSION = 3.12.2;
MARKETING_VERSION = 3.12.3;
MTL_ENABLE_DEBUG_INFO = NO;
MTL_FAST_MATH = YES;
PRODUCT_BUNDLE_IDENTIFIER = com.habitrpg.ios.Habitica.HabiticaIntentsUI;
Expand Down Expand Up @@ -4321,7 +4321,7 @@
"@executable_path/Frameworks",
"@executable_path/../../Frameworks",
);
MARKETING_VERSION = 3.12.2;
MARKETING_VERSION = 3.12.3;
MTL_ENABLE_DEBUG_INFO = NO;
MTL_FAST_MATH = YES;
OTHER_LDFLAGS = "$(inherited)";
Expand Down Expand Up @@ -4455,7 +4455,7 @@
"@executable_path/Frameworks",
);
MACOSX_DEPLOYMENT_TARGET = 13.0;
MARKETING_VERSION = 3.12.2;
MARKETING_VERSION = 3.12.3;
OTHER_LDFLAGS = (
"-ObjC",
"-framework",
Expand Down Expand Up @@ -4599,7 +4599,7 @@
"@executable_path/Frameworks",
"@executable_path/../../Frameworks",
);
MARKETING_VERSION = 3.12.2;
MARKETING_VERSION = 3.12.3;
MTL_ENABLE_DEBUG_INFO = NO;
MTL_FAST_MATH = YES;
OTHER_LDFLAGS = "$(inherited)";
Expand Down Expand Up @@ -4641,7 +4641,7 @@
"@executable_path/Frameworks",
"@executable_path/../../Frameworks",
);
MARKETING_VERSION = 3.12.2;
MARKETING_VERSION = 3.12.3;
MTL_ENABLE_DEBUG_INFO = NO;
MTL_FAST_MATH = YES;
PRODUCT_BUNDLE_IDENTIFIER = com.habitrpg.ios.Habitica.HabiticaIntentsUI;
Expand Down Expand Up @@ -4685,7 +4685,7 @@
"@executable_path/Frameworks",
"@executable_path/../../Frameworks",
);
MARKETING_VERSION = 3.12.2;
MARKETING_VERSION = 3.12.3;
MTL_ENABLE_DEBUG_INFO = NO;
MTL_FAST_MATH = YES;
OTHER_LDFLAGS = "$(inherited)";
Expand Down Expand Up @@ -4826,7 +4826,7 @@
"@executable_path/Frameworks",
"@executable_path/../../Frameworks",
);
MARKETING_VERSION = 3.12.2;
MARKETING_VERSION = 3.12.3;
MTL_ENABLE_DEBUG_INFO = INCLUDE_SOURCE;
MTL_FAST_MATH = YES;
OTHER_LDFLAGS = "$(inherited)";
Expand Down Expand Up @@ -4873,7 +4873,7 @@
"@executable_path/Frameworks",
"@executable_path/../../Frameworks",
);
MARKETING_VERSION = 3.12.2;
MARKETING_VERSION = 3.12.3;
MTL_ENABLE_DEBUG_INFO = NO;
MTL_FAST_MATH = YES;
OTHER_LDFLAGS = "$(inherited)";
Expand Down Expand Up @@ -4914,7 +4914,7 @@
"@executable_path/Frameworks",
"@executable_path/../../Frameworks",
);
MARKETING_VERSION = 3.12.2;
MARKETING_VERSION = 3.12.3;
MTL_ENABLE_DEBUG_INFO = INCLUDE_SOURCE;
MTL_FAST_MATH = YES;
PRODUCT_BUNDLE_IDENTIFIER = com.habitrpg.ios.Habitica.HabiticaIntentsUI;
Expand Down Expand Up @@ -4957,7 +4957,7 @@
"@executable_path/Frameworks",
"@executable_path/../../Frameworks",
);
MARKETING_VERSION = 3.12.2;
MARKETING_VERSION = 3.12.3;
MTL_ENABLE_DEBUG_INFO = NO;
MTL_FAST_MATH = YES;
PRODUCT_BUNDLE_IDENTIFIER = com.habitrpg.ios.Habitica.HabiticaIntentsUI;
Expand Down Expand Up @@ -4998,7 +4998,7 @@
"@executable_path/Frameworks",
"@executable_path/../../Frameworks",
);
MARKETING_VERSION = 3.12.2;
MARKETING_VERSION = 3.12.3;
MTL_ENABLE_DEBUG_INFO = INCLUDE_SOURCE;
MTL_FAST_MATH = YES;
OTHER_LDFLAGS = "$(inherited)";
Expand Down Expand Up @@ -5043,7 +5043,7 @@
"@executable_path/Frameworks",
"@executable_path/../../Frameworks",
);
MARKETING_VERSION = 3.12.2;
MARKETING_VERSION = 3.12.3;
MTL_ENABLE_DEBUG_INFO = NO;
MTL_FAST_MATH = YES;
OTHER_LDFLAGS = "$(inherited)";
Expand Down Expand Up @@ -5354,7 +5354,7 @@
"@executable_path/Frameworks",
);
MACOSX_DEPLOYMENT_TARGET = 13.0;
MARKETING_VERSION = 3.12.2;
MARKETING_VERSION = 3.12.3;
OTHER_LDFLAGS = (
"-ObjC",
"-framework",
Expand Down Expand Up @@ -5427,7 +5427,7 @@
"@executable_path/Frameworks",
);
MACOSX_DEPLOYMENT_TARGET = 13.0;
MARKETING_VERSION = 3.12.2;
MARKETING_VERSION = 3.12.3;
OTHER_LDFLAGS = (
"-ObjC",
"-framework",
Expand Down

0 comments on commit ac565af

Please sign in to comment.