Skip to content

Commit

Permalink
Merge pull request #98 from superwall/develop
Browse files Browse the repository at this point in the history
v1.0.3-beta.1
  • Loading branch information
yusuftor authored Mar 20, 2024
2 parents 23a7844 + ca8a3ec commit 91c8f6f
Show file tree
Hide file tree
Showing 54 changed files with 1,420 additions and 56 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/build+test+deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,7 @@ jobs:
with:
payload: |
{
"text": "Please create a new Android Release! https://github.com/superwall-me/Superwall-Android/releases/new?tag=${{steps.version.outputs.prop}}&prerelease=${{steps.prerelease.outputs.status}}"
"text": "Please create a new Android Release! https://github.com/superwall/Superwall-Android/releases/new?tag=${{steps.version.outputs.prop}}&prerelease=${{steps.prerelease.outputs.status}}"
}
env:
SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK }}
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/on-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,5 +12,5 @@ jobs:
uses: peter-evans/repository-dispatch@98b1133981c5060126325c279a8840c1711a9fe0
with:
token: ${{ secrets.MAIN_REPO_PAT }}
repository: superwall-me/paywall-next
repository: superwall/paywall-next
event-type: android-release
26 changes: 10 additions & 16 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,19 +1,13 @@
*.iml
.gradle
/local.properties
/.idea/caches
/.idea/libraries
/.idea/modules.xml
/.idea/workspace.xml
/.idea/navEditor.xml
/.idea/assetWizardSettings.xml
.DS_Store
/build
/captures
.externalNativeBuild
.cxx
local.properties
.idea/*
**/*.iml
**/.gradle
**/local.properties
**/.DS_Store
**/build
**/captures
**/.externalNativeBuild
**/.cxx
**/local.properties
**/.idea/
private_key.pepk
upload-keystore.jks
.env
17 changes: 16 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,21 @@
# CHANGELOG

The changelog for `Superwall`. Also see the [releases](https://github.com/superwall-me/Superwall-Android/releases) on GitHub.
The changelog for `Superwall`. Also see the [releases](https://github.com/superwall/Superwall-Android/releases) on GitHub.

## 1.0.3-beta.1

### Fixes

- SW-2732: User attributes weren't being sent on app open until identify was called. Now they are
sent every time there's a new session.
- SW-2733: Fixes issue where the spinner would still show on a paywall if a user had previously
purchased on it.
- SW-2744: Fixes issue where using the back button to dismiss a paywall presented via `getPaywall`
would call `didFinish` in the `PaywallViewControllerDelegate` with the incorrect values.
- Fixes issue where an invalid paywall background color would prevent the paywall from opening. If
this happens, it will now default to white.
- SW-2748: Exposes `viewWillAppear`, `viewDidAppear`, `viewWillDisappear` and `viewDidDisappear`
methods of `PaywallViewController` which you must call when using `getPaywall`.

## 1.0.2

Expand Down
8 changes: 4 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,14 +12,14 @@
<a href="https://superwall.com/docs/installation-via-gradle">
<img src="https://img.shields.io/badge/gradle-compatible-informational" alt="Gradle Compatible">
</a>
<a href="https://github.com/superwall-me/Superwall-Android/blob/main/LICENSE">
<a href="https://github.com/superwall/Superwall-Android/blob/main/LICENSE">
<img src="https://img.shields.io/badge/license-MIT-green/" alt="MIT License">
</a>
<a href="https://superwall.com/">
<img src="https://img.shields.io/badge/community-active-9cf" alt="Community Active">
</a>
<a href="https://superwall.com/">
<img src="https://img.shields.io/github/v/tag/superwall-me/Superwall-Android" alt="Version Number">
<img src="https://img.shields.io/github/v/tag/superwall/Superwall-Android" alt="Version Number">
</a>
</p>

Expand All @@ -42,7 +42,7 @@
✏️ | A/B Testing - automatically calculate metrics for different paywalls
📝 | [Online documentation](https://superwall.com/docs/android-beta) up to date
🔀 | [Integrations](https://superwall.com/docs/android-beta) - over a dozen integrations to easily send conversion data where you need it
💯 | Well maintained - [frequent releases](https://github.com/superwall-me/Superwall-Android/releases)
💯 | Well maintained - [frequent releases](https://github.com/superwall/Superwall-Android/releases)
📮 | Great support - email a founder: jake@superwall.com

## Installation
Expand All @@ -55,7 +55,7 @@ The preferred installation method is with [Gradle](https://superwall.com/docs/in

- Open **settings.gradle**
- Add `maven { url 'https://mvn.superwall.com/release' }` to your `repositories { ... }`
- Add `implementation "com.superwall.sdk:superwall-android:<INSERT-LATEST-VERSION>"` [latest version](https://github.com/superwall-me/Superwall-Android/releases)
- Add `implementation "com.superwall.sdk:superwall-android:<INSERT-LATEST-VERSION>"` [latest version](https://github.com/superwall/Superwall-Android/releases)
- Make sure you press `Sync Now`
- Edit your **AndroidManifest.xml** by adding:
```xml
Expand Down
6 changes: 3 additions & 3 deletions app/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,8 @@ android {

defaultConfig {
applicationId = "com.superwall.superapp"
minSdkVersion(26)
targetSdkVersion(33)
minSdk = 26
targetSdk = 34
versionCode = 2
versionName = "1.0.0"

Expand All @@ -20,7 +20,7 @@ android {
}

buildTypes {
getByName("release") {
release {
isMinifyEnabled = false
proguardFiles(
getDefaultProguardFile("proguard-android-optimize.txt"),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,7 @@ fun ComposeActivityContent(@PreviewParameter(PreviewPaywallDelegateProvider::cla
@Composable
fun TabContent0(paywallOverrides: PaywallOverrides?, delegate: PaywallViewControllerDelegate) {
PaywallComposable(
event = "another_paywall",
event = "no_products",
params = mapOf("key" to "value"),
paywallOverrides = paywallOverrides,
delegate = delegate
Expand Down
8 changes: 4 additions & 4 deletions app/src/main/java/com/superwall/superapp/MainApplication.kt
Original file line number Diff line number Diff line change
Expand Up @@ -35,16 +35,16 @@ class MainApplication : android.app.Application(), SuperwallDelegate {
fun configureWithAutomaticInitialization() {
Superwall.configure(
this,
CONSTANT_API_KEY,
CONSTANT_API_KEY
)
Superwall.instance.delegate = this

// Make sure we enable the game controller
Superwall.instance.options.isGameControllerEnabled = true
// Superwall.instance.options.isGameControllerEnabled = true
}

fun configureWithRevenueCatInitialization() {
val purchaseController = RevenueCatPurchaseController(this)
val purchaseController = RevenueCatPurchaseController(this)

Superwall.configure(
this,
Expand All @@ -54,7 +54,7 @@ class MainApplication : android.app.Application(), SuperwallDelegate {
Superwall.instance.delegate = this

// Make sure we enable the game controller
Superwall.instance.options.isGameControllerEnabled = true
// Superwall.instance.options.isGameControllerEnabled = true

purchaseController.syncSubscriptionStatus()
}
Expand Down
15 changes: 15 additions & 0 deletions example/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
*.iml
.gradle
/local.properties
/.idea/caches
/.idea/libraries
/.idea/modules.xml
/.idea/workspace.xml
/.idea/navEditor.xml
/.idea/assetWizardSettings.xml
.DS_Store
/build
/captures
.externalNativeBuild
.cxx
local.properties
File renamed without changes.
72 changes: 72 additions & 0 deletions example/app/build.gradle.kts
Original file line number Diff line number Diff line change
@@ -0,0 +1,72 @@
plugins {
id("com.android.application")
id("org.jetbrains.kotlin.android")
}

android {
namespace = "com.superwall.exampleapp"
compileSdk = 34

defaultConfig {
applicationId = "com.superwall.superapp"
minSdk = 26
targetSdk = 34
versionCode = 1
versionName = "1.0.0"

testInstrumentationRunner = "androidx.test.runner.AndroidJUnitRunner"
vectorDrawables {
useSupportLibrary = true
}
}

buildTypes {
getByName("release") {
isMinifyEnabled = false
proguardFiles(
getDefaultProguardFile("proguard-android-optimize.txt"),
"proguard-rules.pro"
)
}
}
compileOptions {
sourceCompatibility = JavaVersion.VERSION_1_8
targetCompatibility = JavaVersion.VERSION_1_8
}
kotlinOptions {
jvmTarget = "1.8"
}
buildFeatures {
compose = true
}
composeOptions {
kotlinCompilerExtensionVersion = "1.4.7"
}
packagingOptions {
resources.excludes += "/META-INF/{AL2.0,LGPL2.1}"
}
}

dependencies {
implementation(project(":superwall"))

// Billing
implementation(libs.billing)
implementation(libs.revenue.cat)

// Compose
implementation(platform(libs.compose.bom))
implementation(libs.activity.compose)
implementation(libs.ui)
implementation(libs.ui.graphics)
implementation(libs.ui.tooling.preview)
implementation(libs.material3)

// Core
implementation(libs.core)
implementation(libs.appcompat)
implementation(libs.material)
implementation(libs.constraintlayout)
implementation(libs.core.ktx)
implementation(libs.lifecycle.runtime.ktx)
}
21 changes: 21 additions & 0 deletions example/app/proguard-rules.pro
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
# Add project specific ProGuard rules here.
# You can control the set of applied configuration files using the
# proguardFiles setting in build.gradle.
#
# For more details, see
# http://developer.android.com/guide/developing/tools/proguard.html

# If your project uses WebView with JS, uncomment the following
# and specify the fully qualified class name to the JavaScript interface
# class:
#-keepclassmembers class fqcn.of.javascript.interface.for.webview {
# public *;
#}

# Uncomment this to preserve the line number information for
# debugging stack traces.
#-keepattributes SourceFile,LineNumberTable

# If you keep the line number information, uncomment this to
# hide the original source file name.
#-renamesourcefileattribute SourceFile
40 changes: 40 additions & 0 deletions example/app/src/main/AndroidManifest.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools">

<uses-permission android:name="android.permission.INTERNET" />
<uses-permission android:name="com.android.vending.BILLING" />

<application
android:allowBackup="true"
android:dataExtractionRules="@xml/data_extraction_rules"
android:fullBackupContent="@xml/backup_rules"
android:icon="@mipmap/ic_launcher"
android:label="@string/app_name"
android:roundIcon="@mipmap/ic_launcher_round"
android:supportsRtl="true"
android:theme="@style/Theme.SuperwallExampleApp"
tools:targetApi="31">
<activity
android:name=".MainActivity"
android:exported="true"
android:label="@string/app_name"
android:theme="@style/Theme.SuperwallExampleApp">
<intent-filter>
<action android:name="android.intent.action.MAIN" />

<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
<activity
android:name=".HomeActivity"
android:exported="false"
android:label="Home Activity"
android:theme="@style/Theme.SuperwallExampleApp" />
<activity
android:name="com.superwall.sdk.paywall.vc.SuperwallPaywallActivity"
android:theme="@style/Theme.AppCompat.NoActionBar"
android:configChanges="orientation|screenSize|keyboardHidden" />
</application>

</manifest>
Loading

0 comments on commit 91c8f6f

Please sign in to comment.